Index: src/crankshaft/mips64/lithium-codegen-mips64.cc |
diff --git a/src/crankshaft/mips64/lithium-codegen-mips64.cc b/src/crankshaft/mips64/lithium-codegen-mips64.cc |
index c8383d1efdfec9c8b2ed703beef45dc29b5bf02b..eaa9da174ba5f401da3c6f0c0c9335ecc8e7dc66 100644 |
--- a/src/crankshaft/mips64/lithium-codegen-mips64.cc |
+++ b/src/crankshaft/mips64/lithium-codegen-mips64.cc |
@@ -1887,7 +1887,9 @@ void LCodeGen::DoMathMinMax(LMathMinMax* instr) { |
FPURegister right_reg = ToDoubleRegister(right); |
FPURegister result_reg = ToDoubleRegister(instr->result()); |
Label nan, done; |
- if (operation == HMathMinMax::kMathMax) { |
+ if (left_reg.is(right_reg)) { |
ivica.bogosavljevic
2016/12/07 14:59:15
can we move this check to Float64Max?
Ilija.Pavlovic1
2016/12/08 13:50:06
Yes. Now, these checks are in Float(32|64)(Max|Min
|
+ __ Move(result_reg, left_reg); |
+ } else if (operation == HMathMinMax::kMathMax) { |
__ Float64Max(result_reg, left_reg, right_reg, &nan); |
} else { |
DCHECK(operation == HMathMinMax::kMathMin); |