From: Toni Wilen Date: Sat, 12 Oct 2024 07:54:59 +0000 (+0300) Subject: Softfloat warning fixes X-Git-Tag: 5310~4 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=d164fb9672cbec68748f01975a68a5d53dae75a0;p=francis%2Fwinuae.git Softfloat warning fixes --- diff --git a/softfloat/softfloat.cpp b/softfloat/softfloat.cpp index 37f2c892..71a6ee2b 100644 --- a/softfloat/softfloat.cpp +++ b/softfloat/softfloat.cpp @@ -1781,7 +1781,7 @@ int32_t floatx80_to_int32(floatx80 a, float_status *status) return aSign ? (int32_t) 0x80000000 : 0x7FFFFFFF; } #else - if ( ( aExp == 0x7FFF ) && (bits64) ( aSig<<1 ) ) aSign = 0; + if ( ( aExp == 0x7FFF ) && (uint64_t) ( aSig<<1 ) ) aSign = 0; #endif shiftCount = 0x4037 - aExp; if ( shiftCount <= 0 ) shiftCount = 1; @@ -2163,10 +2163,8 @@ floatx80 floatx80_round_to_int(floatx80 a, float_status *status) flag aSign; int32_t aExp; uint64_t lastBitMask, roundBitsMask; - int8_t roundingMode; floatx80 z; - roundingMode = status->float_rounding_mode; aSign = extractFloatx80Sign(a); aExp = extractFloatx80Exp( a ); if ( 0x403E <= aExp ) { @@ -2984,7 +2982,7 @@ floatx80 floatx80_rem(floatx80 a, floatx80 b, uint64_t *q, flag *s, float_status aSig0 = alternateASig0; aSig1 = alternateASig1; zSign = !zSign; - ++* q; + ++*q; } return normalizeRoundAndPackFloatx80(status->floatx80_rounding_precision, diff --git a/softfloat/softfloat_fpsp.cpp b/softfloat/softfloat_fpsp.cpp index d83d3ce3..4ddfcb93 100644 --- a/softfloat/softfloat_fpsp.cpp +++ b/softfloat/softfloat_fpsp.cpp @@ -598,7 +598,6 @@ floatx80 floatx80_cos(floatx80 a, float_status *status) floatx80 floatx80_cosh(floatx80 a, float_status *status) { - flag aSign; int32_t aExp; uint64_t aSig; @@ -607,7 +606,6 @@ floatx80 floatx80_cosh(floatx80 a, float_status *status) aSig = extractFloatx80Frac(a); aExp = extractFloatx80Exp(a); - aSign = extractFloatx80Sign(a); if (aExp == 0x7FFF) { if ((uint64_t) (aSig<<1)) return propagateFloatx80NaNOneArg(a, status); @@ -1578,8 +1576,8 @@ floatx80 floatx80_sin(floatx80 a, float_status *status) | Sine and cosine *----------------------------------------------------------------------------*/ -floatx80 floatx80_sincos(floatx80 a, floatx80 *c, float_status * status) - { +floatx80 floatx80_sincos(floatx80 a, floatx80 *c, float_status *status) +{ flag aSign, xSign, rSign, sSign; int32_t aExp, xExp, rExp, sExp; uint64_t aSig, rSig, sSig;