On 01/22/2018 11:17 AM, Peter Maydell wrote:
>> -void tcg_gen_andi_i64(TCGv_i64 ret, TCGv_i64 arg1, uint64_t arg2);
>> +void tcg_gen_andi_i64(TCGv_i64 ret, TCGv_i64 arg1, int64_t arg2);
> 
> Does changing these types from unsigned to signed definitely
> not result in any possible change in behaviour of frontend
> code if there's now an unintended sign extension ? I thought
> maybe there was, but now I think I was confused and this is safe...

It definitely does not.

For andi, we pass the value along to movi, which always has examined only the
low 32-bits.  For the shifts, we assert the value is 0 <= x < 32.


r~

Reply via email to