Index: src/crankshaft/mips/lithium-codegen-mips.cc |
diff --git a/src/crankshaft/mips/lithium-codegen-mips.cc b/src/crankshaft/mips/lithium-codegen-mips.cc |
index 8be7d297d469ef0d2c875048c1e0b1f0abb91b29..dfd605bb5f241457d8517db0f114ad168a04e4f2 100644 |
--- a/src/crankshaft/mips/lithium-codegen-mips.cc |
+++ b/src/crankshaft/mips/lithium-codegen-mips.cc |
@@ -1764,18 +1764,18 @@ void LCodeGen::DoMathMinMax(LMathMinMax* instr) { |
FPURegister left_reg = ToDoubleRegister(left); |
FPURegister right_reg = ToDoubleRegister(right); |
FPURegister result_reg = ToDoubleRegister(instr->result()); |
+ |
Label nan, done; |
if (operation == HMathMinMax::kMathMax) { |
- __ MaxNaNCheck_d(result_reg, left_reg, right_reg, &nan); |
+ __ Float64Max(result_reg, left_reg, right_reg, &nan); |
} else { |
DCHECK(operation == HMathMinMax::kMathMin); |
- __ MinNaNCheck_d(result_reg, left_reg, right_reg, &nan); |
+ __ Float64Min(result_reg, left_reg, right_reg, &nan); |
} |
__ Branch(&done); |
__ bind(&nan); |
- __ LoadRoot(scratch, Heap::kNanValueRootIndex); |
- __ ldc1(result_reg, FieldMemOperand(scratch, HeapNumber::kValueOffset)); |
+ __ add_d(result_reg, left_reg, right_reg); |
__ bind(&done); |
} |