Lines Matching defs:zSig
169 Packs the sign `zSign', exponent `zExp', and significand `zSig' into a
172 together to form the result. This means that any integer portion of `zSig'
175 than the desired result exponent whenever `zSig' is a complete, normalized
179 INLINE float32 packFloat32( flag zSign, int16 zExp, bits32 zSig )
182 return ( ( (bits32) zSign )<<31 ) + ( ( (bits32) zExp )<<23 ) + zSig;
189 and significand `zSig', and returns the proper single-precision floating-
199 The input significand `zSig' has its binary point between bits 30
201 significand must be normalized or smaller. If `zSig' is not normalized,
203 and it must not require rounding. In the usual case that `zSig' is
209 static float32 roundAndPackFloat32( flag zSign, int16 zExp, bits32 zSig )
233 roundBits = zSig & 0x7F;
237 && ( (sbits32) ( zSig + roundIncrement ) < 0 ) )
246 || ( zSig + roundIncrement < (uint32)0x80000000 );
247 shift32RightJamming( zSig, - zExp, &zSig );
249 roundBits = zSig & 0x7F;
254 zSig = ( zSig + roundIncrement )>>7;
255 zSig &= ~ ( ( ( roundBits ^ 0x40 ) == 0 ) & roundNearestEven );
256 if ( zSig == 0 ) zExp = 0;
257 return packFloat32( zSign, zExp, zSig );
264 and significand `zSig', and returns the proper single-precision floating-
266 `roundAndPackFloat32' except that `zSig' does not have to be normalized.
267 Bit 31 of `zSig' must be zero, and `zExp' must be 1 less than the ``true''
272 normalizeRoundAndPackFloat32( flag zSign, int16 zExp, bits32 zSig )
276 shiftCount = countLeadingZeros32( zSig ) - 1;
277 return roundAndPackFloat32( zSign, zExp - shiftCount, zSig<<shiftCount );
799 bits32 aSig, bSig, zSig;
843 zSig = 0x40000000 + aSig + bSig;
848 zSig = ( aSig + bSig )<<1;
850 if ( (sbits32) zSig < 0 ) {
851 zSig = aSig + bSig;
855 return roundAndPackFloat32( zSign, zExp, zSig );
871 bits32 aSig, bSig, zSig;
909 zSig = bSig - aSig;
927 zSig = aSig - bSig;
931 return normalizeRoundAndPackFloat32( zSign, zExp, zSig );
1049 bits32 aSig, bSig, zSig, rem0, rem1, term0, term1;
1093 zSig = estimateDiv64To32( aSig, 0, bSig );
1094 if ( ( zSig & 0x3F ) <= 2 ) {
1095 mul32To64( bSig, zSig, &term0, &term1 );
1098 --zSig;
1101 zSig |= ( rem1 != 0 );
1103 return roundAndPackFloat32( zSign, zExp, zSig );
1206 bits32 aSig, zSig, rem0, rem1, term0, term1;
1228 zSig = estimateSqrt32( aExp, aSig ) + 2;
1229 if ( ( zSig & 0x7F ) <= 5 ) {
1230 if ( zSig < 2 ) {
1231 zSig = 0x7FFFFFFF;
1236 mul32To64( zSig, zSig, &term0, &term1 );
1239 --zSig;
1240 shortShift64Left( 0, zSig, 1, &term0, &term1 );
1244 zSig |= ( ( rem0 | rem1 ) != 0 );
1247 shift32RightJamming( zSig, 1, &zSig );
1249 return roundAndPackFloat32( 0, zExp, zSig );
1543 bits32 aSig0, aSig1, zSig;
1556 shift64RightJamming( aSig0, aSig1, 22, &allZero, &zSig );
1557 if ( aExp ) zSig |= 0x40000000;
1558 return roundAndPackFloat32( aSign, aExp - 0x381, zSig );