| Index: src/mips/lithium-codegen-mips.cc
|
| diff --git a/src/mips/lithium-codegen-mips.cc b/src/mips/lithium-codegen-mips.cc
|
| index 3a290117d9f531c3d737920cb154b048b383777e..5c1edaa1c3762f43fdef317ee5c46956d557e681 100644
|
| --- a/src/mips/lithium-codegen-mips.cc
|
| +++ b/src/mips/lithium-codegen-mips.cc
|
| @@ -4590,9 +4590,7 @@ void LCodeGen::DoInteger32ToDouble(LInteger32ToDouble* instr) {
|
|
|
| void LCodeGen::DoInteger32ToSmi(LInteger32ToSmi* instr) {
|
| LOperand* input = instr->value();
|
| - ASSERT(input->IsRegister());
|
| LOperand* output = instr->result();
|
| - ASSERT(output->IsRegister());
|
| Register scratch = scratch0();
|
|
|
| __ SmiTagCheckOverflow(ToRegister(output), ToRegister(input), scratch);
|
| @@ -4613,6 +4611,19 @@ void LCodeGen::DoUint32ToDouble(LUint32ToDouble* instr) {
|
| }
|
|
|
|
|
| +void LCodeGen::DoUint32ToSmi(LUint32ToSmi* instr) {
|
| + LOperand* input = instr->value();
|
| + LOperand* output = instr->result();
|
| + if (!instr->hydrogen()->value()->HasRange() ||
|
| + !instr->hydrogen()->value()->range()->IsInSmiRange()) {
|
| + Register scratch = scratch0();
|
| + __ And(scratch, ToRegister(input), Operand(0xc0000000));
|
| + DeoptimizeIf(ne, instr->environment(), scratch, Operand(zero_reg));
|
| + }
|
| + __ SmiTag(ToRegister(output), ToRegister(input));
|
| +}
|
| +
|
| +
|
| void LCodeGen::DoNumberTagI(LNumberTagI* instr) {
|
| class DeferredNumberTagI: public LDeferredCode {
|
| public:
|
|
|