Index: src/arm/lithium-arm.cc |
diff --git a/src/arm/lithium-arm.cc b/src/arm/lithium-arm.cc |
index 0dda5bdaa1416fae1802f457cfa91a533bb18c47..f8f91448ac3ebbf865d62ea632cf9d1fd20515dd 100644 |
--- a/src/arm/lithium-arm.cc |
+++ b/src/arm/lithium-arm.cc |
@@ -1359,6 +1359,25 @@ LInstruction* LChunkBuilder::DoAdd(HAdd* instr) { |
} |
+LInstruction* LChunkBuilder::DoMathMinMax(HMathMinMax* instr) { |
+ LOperand* left = NULL; |
+ LOperand* right = NULL; |
+ if (instr->representation().IsInteger32()) { |
+ ASSERT(instr->left()->representation().IsInteger32()); |
+ ASSERT(instr->right()->representation().IsInteger32()); |
+ left = UseRegisterAtStart(instr->LeastConstantOperand()); |
+ right = UseOrConstantAtStart(instr->MostConstantOperand()); |
+ } else { |
+ ASSERT(instr->representation().IsDouble()); |
+ ASSERT(instr->left()->representation().IsDouble()); |
+ ASSERT(instr->right()->representation().IsDouble()); |
+ left = UseRegisterAtStart(instr->left()); |
+ right = UseRegisterAtStart(instr->right()); |
+ } |
+ return DefineAsRegister(new(zone()) LMathMinMax(left, right)); |
+} |
+ |
+ |
LInstruction* LChunkBuilder::DoPower(HPower* instr) { |
ASSERT(instr->representation().IsDouble()); |
// We call a C function for double power. It can't trigger a GC. |