mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-16 04:59:25 +02:00
* softfpu.pp: fixed two more porting bugs, and also added two typecasts to avoid unnecessary 64-bit operations.
git-svn-id: trunk@28609 -
This commit is contained in:
parent
e4095588d6
commit
5279693919
@ -612,13 +612,13 @@ begin
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
roundBits := absZ and $7F;
|
||||
roundBits := lo(absZ) and $7F;
|
||||
absZ := ( absZ + roundIncrement ) shr 7;
|
||||
absZ := absZ and not( ord( ( roundBits xor $40 ) = 0 ) and ord(roundNearestEven) );
|
||||
absZ := absZ and not( bits64( ord( ( roundBits xor $40 ) = 0 ) and ord(roundNearestEven) ));
|
||||
z := absZ;
|
||||
if ( zSign<>0 ) then
|
||||
z := - z;
|
||||
if ( ( absZ shr 32 ) or ( z and ( ord( z < 0 ) xor zSign ) ) )<>0 then
|
||||
if ( longint(hi( absZ )) or ( z and ( ord( z < 0 ) xor zSign ) ) )<>0 then
|
||||
begin
|
||||
float_raise( float_flag_invalid );
|
||||
if zSign<>0 then
|
||||
@ -1602,7 +1602,7 @@ Begin
|
||||
z := ( z shl 15 );
|
||||
if ( z <= a ) then
|
||||
Begin
|
||||
estimateSqrt32 := bits32 ( ( sbits32 (a )) shr 1 );
|
||||
estimateSqrt32 := bits32 ( SarLongint( sbits32 (a)) );
|
||||
exit;
|
||||
End;
|
||||
End;
|
||||
|
Loading…
Reference in New Issue
Block a user