[X87] [crankshaft] Set Floating-point precision in Math.Cos/Math.Sin to standard double precision.
This CL set Floating-point precision in Math.Cos/Math.Sin in Crankshaft compiler to standard double precision which is expected by v8. BUG= Review-Url: https://codereview.chromium.org/2403803002 Cr-Commit-Position: refs/heads/master@{#40146}
This commit is contained in:
parent
127798897f
commit
ecc7d969ea
@ -3660,7 +3660,9 @@ void LCodeGen::DoMathCos(LMathCos* instr) {
|
||||
__ PrepareCallCFunction(2, eax);
|
||||
__ fstp_d(MemOperand(esp, 0));
|
||||
X87PrepareToWrite(result);
|
||||
__ X87SetFPUCW(0x027F);
|
||||
__ CallCFunction(ExternalReference::ieee754_cos_function(isolate()), 2);
|
||||
__ X87SetFPUCW(0x037F);
|
||||
// Return value is in st(0) on ia32.
|
||||
X87CommitWrite(result);
|
||||
}
|
||||
@ -3674,7 +3676,9 @@ void LCodeGen::DoMathSin(LMathSin* instr) {
|
||||
__ PrepareCallCFunction(2, eax);
|
||||
__ fstp_d(MemOperand(esp, 0));
|
||||
X87PrepareToWrite(result);
|
||||
__ X87SetFPUCW(0x027F);
|
||||
__ CallCFunction(ExternalReference::ieee754_sin_function(isolate()), 2);
|
||||
__ X87SetFPUCW(0x037F);
|
||||
// Return value is in st(0) on ia32.
|
||||
X87CommitWrite(result);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user