qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] tcg/arm: Fix double-word comparisons


From: Richard Henderson
Subject: Re: [Qemu-devel] [PATCH] tcg/arm: Fix double-word comparisons
Date: Mon, 15 Jan 2018 09:31:43 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2

On 01/15/2018 06:27 AM, Peter Maydell wrote:
> We could avoid the annoying "load LE/GE immediates to tempreg"
> extra code by having tcg_out_cmp2() return a flag to tell
> the caller which way round to put the conditions for its two
> conditional ARITH_MOV insns (for setcond2) or which condition
> to use for the branch (brcond2), right?

No.

We do return a condition to use for the user.  When we do the LE/GT load
immediates to temp path, we do apply tcg_cond_swap(cond), which converts the
condition as for swapped arguments, i.e. to GE/LT.

But we can't *not* swap the arguments to the generated comparison.  Otherwise
we're computing the wrong thing.


r~



reply via email to

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