qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v3 4/8] target/mips: Avoid case statements formu


From: Richard Henderson
Subject: Re: [Qemu-devel] [PATCH v3 4/8] target/mips: Avoid case statements formulated by ranges
Date: Thu, 5 Jul 2018 08:49:55 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0

On 07/04/2018 12:30 PM, Aleksandar Markovic wrote:
>      case 18:
>          switch (sel) {
> -        case 0 ... 7:
> +        case 0:
> +        case 1:
> +        case 2:
> +        case 3:
> +        case 4:
> +        case 5:
> +        case 6:
> +        case 7:

I don't see the point in this.  It is clear what 0 ... 7 means.

> -    case OPC_MULT ... OPC_DIVU:
> +    case OPC_MULT:
> +    case OPC_MULTU:
> +    case OPC_DIV:
> +    case OPC_DIVU:

These on the other hand are a good cleanup, because there's no obvious
relationship between the beginning and end of the range.


r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]