mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-10-27 11:31:27 +01:00
- i386 and x86_64: Once softfloat stuff has been cleaned up, SysResetFPU and SysInitFPU end up doing exactly the same. Removed one of them.
git-svn-id: trunk@27280 -
This commit is contained in:
parent
bd75abb64b
commit
d1348d3f9b
@ -1327,10 +1327,6 @@ const
|
|||||||
FPU_StackOverflow = $40;
|
FPU_StackOverflow = $40;
|
||||||
FPU_ExceptionMask = $ff;
|
FPU_ExceptionMask = $ff;
|
||||||
|
|
||||||
{ use Default8087CW instead
|
|
||||||
fpucw : word = $1300 or FPU_StackUnderflow or FPU_Underflow or FPU_Denormal;
|
|
||||||
}
|
|
||||||
|
|
||||||
MM_MaskInvalidOp = %0000000010000000;
|
MM_MaskInvalidOp = %0000000010000000;
|
||||||
MM_MaskDenorm = %0000000100000000;
|
MM_MaskDenorm = %0000000100000000;
|
||||||
MM_MaskDivZero = %0000001000000000;
|
MM_MaskDivZero = %0000001000000000;
|
||||||
@ -1343,25 +1339,7 @@ const
|
|||||||
|
|
||||||
{$define FPC_SYSTEM_HAS_SYSINITFPU}
|
{$define FPC_SYSTEM_HAS_SYSINITFPU}
|
||||||
Procedure SysInitFPU;
|
Procedure SysInitFPU;
|
||||||
var
|
|
||||||
{ these locals are so we don't have to hack pic code in the assembler }
|
|
||||||
localmxcsr: dword;
|
|
||||||
localfpucw: word;
|
|
||||||
begin
|
begin
|
||||||
localfpucw:=Default8087CW;
|
|
||||||
asm
|
|
||||||
fninit
|
|
||||||
fldcw localfpucw
|
|
||||||
fwait
|
|
||||||
end;
|
|
||||||
if has_sse_support then
|
|
||||||
begin
|
|
||||||
localmxcsr:=mxcsr;
|
|
||||||
asm
|
|
||||||
{ setup sse exceptions }
|
|
||||||
ldmxcsr localmxcsr
|
|
||||||
end;
|
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
@ -1432,8 +1410,6 @@ procedure fpc_cpucodeinit;
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
SysResetFPU;
|
SysResetFPU;
|
||||||
if not(IsLibrary) then
|
|
||||||
SysInitFPU;
|
|
||||||
{$ifdef USE_FASTMOVE}
|
{$ifdef USE_FASTMOVE}
|
||||||
setup_fastmove;
|
setup_fastmove;
|
||||||
{$endif}
|
{$endif}
|
||||||
|
|||||||
@ -925,8 +925,6 @@ const
|
|||||||
FPU_StackOverflow = $40;
|
FPU_StackOverflow = $40;
|
||||||
FPU_ExceptionMask = $ff;
|
FPU_ExceptionMask = $ff;
|
||||||
|
|
||||||
fpucw : word = $1300 or FPU_StackUnderflow or FPU_Underflow or FPU_Denormal;
|
|
||||||
|
|
||||||
MM_MaskInvalidOp = %0000000010000000;
|
MM_MaskInvalidOp = %0000000010000000;
|
||||||
MM_MaskDenorm = %0000000100000000;
|
MM_MaskDenorm = %0000000100000000;
|
||||||
MM_MaskDivZero = %0000001000000000;
|
MM_MaskDivZero = %0000001000000000;
|
||||||
@ -945,25 +943,11 @@ procedure fpc_cpuinit;
|
|||||||
mxcsr:=GetSSECSR;
|
mxcsr:=GetSSECSR;
|
||||||
end;
|
end;
|
||||||
SysResetFPU;
|
SysResetFPU;
|
||||||
if not(IsLibrary) then
|
|
||||||
SysInitFPU;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{$define FPC_SYSTEM_HAS_SYSINITFPU}
|
{$define FPC_SYSTEM_HAS_SYSINITFPU}
|
||||||
Procedure SysInitFPU;
|
Procedure SysInitFPU;
|
||||||
var
|
|
||||||
{ these locals are so we don't have to hack pic code in the assembler }
|
|
||||||
localmxcsr: dword;
|
|
||||||
localfpucw: word;
|
|
||||||
|
|
||||||
begin
|
begin
|
||||||
localmxcsr:=mxcsr;
|
|
||||||
localfpucw:=fpucw;
|
|
||||||
asm
|
|
||||||
fldcw localfpucw
|
|
||||||
{ set sse exceptions }
|
|
||||||
ldmxcsr localmxcsr
|
|
||||||
end ['RAX'];
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user