[Qemu-devel] [PATCH v3 05/20] tcg-arm: Handle constant arguments to add2/sub2

2013-03-28 Thread Richard Henderson
We get to re-use the _rIN and _rIK subroutines to handle the various combinations of add vs sub. Fold the 21 into the opcode enum values so that we can explicitly add TO_CPSR as desired. Signed-off-by: Richard Henderson r...@twiddle.net --- tcg/arm/tcg-target.c | 106

Re: [Qemu-devel] [PATCH v3 05/20] tcg-arm: Handle constant arguments to add2/sub2

2013-03-28 Thread Peter Maydell
On 28 March 2013 15:32, Richard Henderson r...@twiddle.net wrote: We get to re-use the _rIN and _rIK subroutines to handle the various combinations of add vs sub. Fold the 21 into the opcode enum values so that we can explicitly add TO_CPSR as desired. Signed-off-by: Richard Henderson

Re: [Qemu-devel] [PATCH v3 05/20] tcg-arm: Handle constant arguments to add2/sub2

2013-03-28 Thread Richard Henderson
On 03/28/2013 08:56 AM, Peter Maydell wrote: +#define TO_CPSR (1 20) This is the S bit; I think it would be helpful if our #define had a name that made that clearer... Suggestions? I thought TO_CPSR was clear... +ARITH_TST = 0x8 21 | TO_CPSR, +ARITH_CMP = 0xa 21 | TO_CPSR, +

Re: [Qemu-devel] [PATCH v3 05/20] tcg-arm: Handle constant arguments to add2/sub2

2013-03-28 Thread Laurent Desnogues
On Thu, Mar 28, 2013 at 5:04 PM, Richard Henderson r...@twiddle.net wrote: On 03/28/2013 08:56 AM, Peter Maydell wrote: +#define TO_CPSR (1 20) This is the S bit; I think it would be helpful if our #define had a name that made that clearer... Suggestions? I thought TO_CPSR was clear...

Re: [Qemu-devel] [PATCH v3 05/20] tcg-arm: Handle constant arguments to add2/sub2

2013-03-28 Thread Richard Henderson
On 03/28/2013 09:09 AM, Laurent Desnogues wrote: I think it actually makes everything a lot cleaner myself. Especially given the previous definition that required runtime checks for TST et al. I also find this cleaner. OTOH I understand that Peter finds it odd given that other operations