diff options
author | Richard Henderson <richard.henderson@linaro.org> | 2020-09-23 14:58:59 -0700 |
---|---|---|
committer | Richard Henderson <richard.henderson@linaro.org> | 2021-05-16 07:13:51 -0500 |
commit | 9793c1e224a30252dfa7ca3c1f7a5c4827ca4cfc (patch) | |
tree | 8966fb8607a98ff84652158c39c752a0da27e2f0 /fpu | |
parent | d82f3b2dc7d0efe0fcb0cec884c2d0803b9fd4de (diff) |
softfloat: Tidy a * b + inf return
No reason to set values in 'a', when we already
have float_class_inf in 'c', and can flip that sign.
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: David Hildenbrand <david@redhat.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'fpu')
-rw-r--r-- | fpu/softfloat.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/fpu/softfloat.c b/fpu/softfloat.c index 93fe785809..ee4b5073b6 100644 --- a/fpu/softfloat.c +++ b/fpu/softfloat.c @@ -1384,9 +1384,8 @@ static FloatParts muladd_floats(FloatParts a, FloatParts b, FloatParts c, float_raise(float_flag_invalid, s); return parts_default_nan(s); } else { - a.cls = float_class_inf; - a.sign = c.sign ^ sign_flip; - return a; + c.sign ^= sign_flip; + return c; } } |