| Index: src/x64/lithium-x64.cc
|
| diff --git a/src/x64/lithium-x64.cc b/src/x64/lithium-x64.cc
|
| index 0f7ebc44fb510c4a02a58d2d11411b6062ccfc9a..473e93dde6f42369619e1198ee1d96d2dc4d7888 100644
|
| --- a/src/x64/lithium-x64.cc
|
| +++ b/src/x64/lithium-x64.cc
|
| @@ -1585,15 +1585,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());
|
| }
|
|
|