| Index: src/x64/lithium-x64.cc
|
| diff --git a/src/x64/lithium-x64.cc b/src/x64/lithium-x64.cc
|
| index e77e657671e9b1d2b2a713a244f7d0a14a13b867..7a9e86edd10a4b0001e9dcd5d6647120b3235d22 100644
|
| --- a/src/x64/lithium-x64.cc
|
| +++ b/src/x64/lithium-x64.cc
|
| @@ -1435,15 +1435,16 @@ LInstruction* LChunkBuilder::DoAdd(HAdd* instr) {
|
| LInstruction* LChunkBuilder::DoMathMinMax(HMathMinMax* instr) {
|
| LOperand* left = NULL;
|
| LOperand* right = NULL;
|
| - if (instr->representation().IsSmiOrInteger32()) {
|
| - ASSERT(instr->left()->representation().Equals(instr->representation()));
|
| - ASSERT(instr->right()->representation().Equals(instr->representation()));
|
| + ASSERT(instr->left()->representation().Equals(instr->representation()));
|
| + ASSERT(instr->right()->representation().Equals(instr->representation()));
|
| + if (instr->representation().IsSmi()) {
|
| + left = UseRegisterAtStart(instr->BetterLeftOperand());
|
| + right = UseAtStart(instr->BetterRightOperand());
|
| + } else if (instr->representation().IsInteger32()) {
|
| left = UseRegisterAtStart(instr->BetterLeftOperand());
|
| right = UseOrConstantAtStart(instr->BetterRightOperand());
|
| } else {
|
| ASSERT(instr->representation().IsDouble());
|
| - ASSERT(instr->left()->representation().IsDouble());
|
| - ASSERT(instr->right()->representation().IsDouble());
|
| left = UseRegisterAtStart(instr->left());
|
| right = UseRegisterAtStart(instr->right());
|
| }
|
|
|