[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v3 2/5] target-tricore: Added MADD.F and MSUB.F
From: |
Richard Henderson |
Subject: |
Re: [Qemu-devel] [PATCH v3 2/5] target-tricore: Added MADD.F and MSUB.F instructions |
Date: |
Fri, 11 Nov 2016 15:57:05 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 |
On 11/11/2016 03:20 PM, Bastian Koppelmann wrote:
+ if (muladd_negate_c) {
+ cSign ^= 1;
+ }
+ if (((aExp == 0xff) || (bExp == 0xff)) && (cExp == 0xff)) {
+ if (aSign ^ bSign ^ cSign) {
If you're going to make muladd_negate_c a bool, you might as well just fold
that in here:
if (aSign ^ bSign ^ cSign ^ muladd_negate_c)
And, come to think of it,
+ arg1 = float32_squash_input_denormal(arg1, &env->fp_status);
+ arg2 = float32_squash_input_denormal(arg2, &env->fp_status);
+ arg3 = float32_squash_input_denormal(arg3, &env->fp_status);
can be folded into f_maddsub_nan_result as
} else if (float32_is_infinity(arg1)
&& float32_is_zero(float32_squash_input_denormal
(arg2, &env->fp_status))) {
return MUL_NAN;
} else if (float32_is_infinity(arg2)
&& float32_is_zero(float32_squash_input_denormal
(arg1, &env->fp_status))) {
return MUL_NAN;
which makes it less likely that the squash will actually be call
Otherwise,
Reviewed-by: Richard Henderson <address@hidden>
r~
- [Qemu-devel] [PATCH v3 0/5] Added 7 instructions to the tricore target, Bastian Koppelmann, 2016/11/11
- [Qemu-devel] [PATCH v3 3/5] target-tricore: Added new MOV instruction variant, Bastian Koppelmann, 2016/11/11
- [Qemu-devel] [PATCH v3 4/5] target-tricore: Added new JNE instruction variant, Bastian Koppelmann, 2016/11/11
- [Qemu-devel] [PATCH v3 1/5] target-tricore: Added FTOUZ instruction, Bastian Koppelmann, 2016/11/11
- [Qemu-devel] [PATCH v3 2/5] target-tricore: Added MADD.F and MSUB.F instructions, Bastian Koppelmann, 2016/11/11
- [Qemu-devel] [PATCH v3 5/5] target-tricore: Add updfl instruction, Bastian Koppelmann, 2016/11/11