qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH for-2.11 22/23] tcg/ppc: Look for shifted consta


From: Richard Henderson
Subject: Re: [Qemu-devel] [PATCH for-2.11 22/23] tcg/ppc: Look for shifted constants
Date: Fri, 4 Aug 2017 09:58:46 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1

On 08/04/2017 09:39 AM, Philippe Mathieu-Daudé wrote:
>>   @@ -638,6 +639,14 @@ static void tcg_out_movi_int(TCGContext *s, TCGType
>> type, TCGReg ret,
>>           return;
>>       }
>>   +    lsb = ctz64(arg);
>> +    high = arg >> lsb;
>> +    if (arg == (int16_t)arg) {
> 
> Can you move these here?
> 
> +    lsb = ctz64(arg);
> +    high = arg >> lsb;

No, because you've found a bug -- the if should be testing high, not arg.  ;-)

Thanks,


r~



reply via email to

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