Browse Source

* disable SSE optimized Frac() for Win64; it has a much lower supported range than the existing Pascal implementation which uses Int() (in essence Round() and Trunc() should be corrected as well)

git-svn-id: trunk@38856 -
svenbarth 7 years ago
parent
commit
e3ea46d1cb
1 changed files with 2 additions and 0 deletions
  1. 2 0
      rtl/x86_64/math.inc

+ 2 - 0
rtl/x86_64/math.inc

@@ -372,6 +372,7 @@ const
       end;
       end;
     {$endif FPC_SYSTEM_HAS_ROUND}
     {$endif FPC_SYSTEM_HAS_ROUND}
 
 
+    {$ifdef ENABLE_RESTRICTED_SSE_FRAC}
     {$ifndef FPC_SYSTEM_HAS_FRAC}
     {$ifndef FPC_SYSTEM_HAS_FRAC}
     {$define FPC_SYSTEM_HAS_FRAC}
     {$define FPC_SYSTEM_HAS_FRAC}
     function fpc_frac_real(d: ValReal) : ValReal;compilerproc; assembler; nostackframe;
     function fpc_frac_real(d: ValReal) : ValReal;compilerproc; assembler; nostackframe;
@@ -383,5 +384,6 @@ const
         subsd       %xmm4,%xmm0
         subsd       %xmm4,%xmm0
       end;
       end;
     {$endif FPC_SYSTEM_HAS_FRAC}
     {$endif FPC_SYSTEM_HAS_FRAC}
+    {$endif ENABLE_RESTRICTED_SSE_FRAC}
 
 
 {$endif FPC_HAS_TYPE_EXTENDED}
 {$endif FPC_HAS_TYPE_EXTENDED}