path: root/fpu/softfloat.c
diff options
authorPeter Maydell <peter.maydell@linaro.org>2012-09-24 17:28:35 +0100
committerAurelien Jarno <aurelien@aurel32.net>2012-10-01 22:06:39 +0200
commit4be8eeacb9f2b01ad98747ad88e54a7feabc664c (patch)
tree6ac223987b862445c6fdf585a5d0ed3d7290c3dc /fpu/softfloat.c
parent0f41dc182c7e4e2ae160641552101a2a199f7c4c (diff)
fpu/softfloat.c: Remove pointless shift of always-zero value
In float16_to_float32, when returning an infinity, just pass zero as the mantissa argument to packFloat32(), rather than shifting a value which we know must be zero. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Diffstat (limited to 'fpu/softfloat.c')
1 files changed, 1 insertions, 1 deletions
diff --git a/fpu/softfloat.c b/fpu/softfloat.c
index b29256a8eb..01a28cab1a 100644
--- a/fpu/softfloat.c
+++ b/fpu/softfloat.c
@@ -3007,7 +3007,7 @@ float32 float16_to_float32(float16 a, flag ieee STATUS_PARAM)
if (aSig) {
return commonNaNToFloat32(float16ToCommonNaN(a STATUS_VAR) STATUS_VAR);
- return packFloat32(aSign, 0xff, aSig << 13);
+ return packFloat32(aSign, 0xff, 0);
if (aExp == 0) {
int8 shiftCount;