Commit ebb0f57e authored by zhengxing.li's avatar zhengxing.li Committed by Commit bot

[crankshaft][X87] Fix Math.min(-0, -0)

  The CL #33996 (https://codereview.chromium.org/1695283002) exposed one hidden bug in x87 crankshaft code generation for LCodeGen::DoMathMinMax().

  This CL fixed this bug.

BUG=

Review URL: https://codereview.chromium.org/1715263002

Cr-Commit-Position: refs/heads/master@{#34183}
parent 4453164d
...@@ -2080,7 +2080,7 @@ void LCodeGen::DoMathMinMax(LMathMinMax* instr) { ...@@ -2080,7 +2080,7 @@ void LCodeGen::DoMathMinMax(LMathMinMax* instr) {
__ fstp_s(MemOperand(esp, 0)); __ fstp_s(MemOperand(esp, 0));
__ fstp_s(MemOperand(esp, kPointerSize)); __ fstp_s(MemOperand(esp, kPointerSize));
__ pop(scratch_reg); __ pop(scratch_reg);
__ xor_(MemOperand(esp, 0), scratch_reg); __ or_(MemOperand(esp, 0), scratch_reg);
X87Mov(left_reg, MemOperand(esp, 0), kX87FloatOperand); X87Mov(left_reg, MemOperand(esp, 0), kX87FloatOperand);
__ pop(scratch_reg); // restore esp __ pop(scratch_reg); // restore esp
} else { } else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment