Browse Source

* Don't generate x87 instructions for sin and cos on win64, somehow managed to not commit this part in r25995. Mantis #17273.

git-svn-id: trunk@26094 -
sergei 11 years ago
parent
commit
bca2c464da
1 changed files with 14 additions and 4 deletions
  1. 14 4
      compiler/x86/nx86inl.pas

+ 14 - 4
compiler/x86/nx86inl.pas

@@ -160,8 +160,13 @@ implementation
             exit;
           end;
 {$endif i8086}
-        expectloc:=LOC_FPUREGISTER;
-        first_cos_real := nil;
+        if (tfloatdef(pbestrealtype^).floattype=s80real) then
+          begin
+            expectloc:=LOC_FPUREGISTER;
+            result:=nil;
+          end
+        else
+          result:=inherited;
       end;
 
      function tx86inlinenode.first_sin_real : tnode;
@@ -174,8 +179,13 @@ implementation
             exit;
           end;
 {$endif i8086}
-        expectloc:=LOC_FPUREGISTER;
-        first_sin_real := nil;
+        if (tfloatdef(pbestrealtype^).floattype=s80real) then
+          begin
+            expectloc:=LOC_FPUREGISTER;
+            result:=nil;
+          end
+        else
+          result:=inherited;
       end;