Index: src/mips/lithium-codegen-mips.cc |
diff --git a/src/mips/lithium-codegen-mips.cc b/src/mips/lithium-codegen-mips.cc |
index 13057347f4f6af4058a529854ce09b37f32f6789..428da02e702d7f4dfb1b87f573e4d8d19de22b2c 100644 |
--- a/src/mips/lithium-codegen-mips.cc |
+++ b/src/mips/lithium-codegen-mips.cc |
@@ -3844,7 +3844,7 @@ void LCodeGen::EmitNumberUntagD(Register input_reg, |
Label load_smi, heap_number, done; |
// Smi check. |
- __ JumpIfSmi(input_reg, &load_smi); |
+ __ UntagAndJumpIfSmi(scratch, input_reg, &load_smi); |
// Heap number map check. |
__ lw(scratch, FieldMemOperand(input_reg, HeapObject::kMapOffset)); |
@@ -3877,7 +3877,7 @@ void LCodeGen::EmitNumberUntagD(Register input_reg, |
// Smi to double register conversion |
__ bind(&load_smi); |
- __ SmiUntag(scratch, input_reg); // Untag smi before converting to float. |
+ // scratch: untagged value of input_reg |
__ mtc1(scratch, result_reg); |
__ cvt_d_w(result_reg, result_reg); |
__ bind(&done); |
@@ -4160,7 +4160,7 @@ void LCodeGen::DoClampTToUint8(LClampTToUint8* instr) { |
Label is_smi, done, heap_number; |
// Both smi and heap number cases are handled. |
- __ JumpIfSmi(input_reg, &is_smi); |
+ __ UntagAndJumpIfSmi(scratch, input_reg, &is_smi); |
// Check for heap number |
__ lw(scratch, FieldMemOperand(input_reg, HeapObject::kMapOffset)); |
@@ -4180,9 +4180,7 @@ void LCodeGen::DoClampTToUint8(LClampTToUint8* instr) { |
__ ClampDoubleToUint8(result_reg, double_scratch0(), temp_reg); |
__ jmp(&done); |
- // smi |
__ bind(&is_smi); |
- __ SmiUntag(scratch, input_reg); |
__ ClampUint8(result_reg, scratch); |
__ bind(&done); |