softfloat: do not set denominator high bit for floatx80 remainder
authorJoseph Myers <joseph@codesourcery.com>
Mon, 8 Jun 2020 16:56:47 +0000 (16:56 +0000)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 26 Jun 2020 13:39:38 +0000 (09:39 -0400)
The floatx80 remainder implementation unnecessarily sets the high bit
of bSig explicitly.  By that point in the function, arguments that are
invalid, zero, infinity or NaN have already been handled and
subnormals have been through normalizeFloatx80Subnormal, so the high
bit will already be set.  Remove the unnecessary code.

Signed-off-by: Joseph Myers <joseph@codesourcery.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <alpine.DEB.2.21.2006081656220.23637@digraph.polyomino.org.uk>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
fpu/softfloat.c

index ab50088c35c52df9cfbfb7231deba9f21d5c0446..1ee33427153a51b4e467fa30bf690f974274c2c3 100644 (file)
@@ -5751,7 +5751,6 @@ floatx80 floatx80_modrem(floatx80 a, floatx80 b, bool mod,
         if ( aSig0 == 0 ) return a;
         normalizeFloatx80Subnormal( aSig0, &aExp, &aSig0 );
     }
-    bSig |= UINT64_C(0x8000000000000000);
     zSign = aSign;
     expDiff = aExp - bExp;
     aSig1 = 0;