Index: src/mips/stub-cache-mips.cc |
diff --git a/src/mips/stub-cache-mips.cc b/src/mips/stub-cache-mips.cc |
index 85497b5fc3bb2b3f9b4bd5abd30e8578e84faec8..c69cf92172032cd80870ffc250808a46ec861339 100644 |
--- a/src/mips/stub-cache-mips.cc |
+++ b/src/mips/stub-cache-mips.cc |
@@ -3695,6 +3695,7 @@ static void GenerateSmiKeyCheck(MacroAssembler* masm, |
Register scratch0, |
Register scratch1, |
FPURegister double_scratch0, |
+ FPURegister double_scratch1, |
Label* fail) { |
if (CpuFeatures::IsSupported(FPU)) { |
CpuFeatures::Scope scope(FPU); |
@@ -3710,15 +3711,15 @@ static void GenerateSmiKeyCheck(MacroAssembler* masm, |
DONT_DO_SMI_CHECK); |
__ ldc1(double_scratch0, FieldMemOperand(key, HeapNumber::kValueOffset)); |
__ EmitFPUTruncate(kRoundToZero, |
- double_scratch0, |
- double_scratch0, |
scratch0, |
+ double_scratch0, |
+ at, |
+ double_scratch1, |
scratch1, |
kCheckForInexactConversion); |
__ Branch(fail, ne, scratch1, Operand(zero_reg)); |
- __ mfc1(scratch0, double_scratch0); |
__ SmiTagCheckOverflow(key, scratch0, scratch1); |
__ BranchOnOverflow(fail, scratch1); |
__ bind(&key_ok); |
@@ -3746,7 +3747,7 @@ void KeyedLoadStubCompiler::GenerateLoadExternalArray( |
// have been verified by the caller to not be a smi. |
// Check that the key is a smi or a heap number convertible to a smi. |
- GenerateSmiKeyCheck(masm, key, t0, t1, f2, &miss_force_generic); |
+ GenerateSmiKeyCheck(masm, key, t0, t1, f2, f4, &miss_force_generic); |
__ lw(a3, FieldMemOperand(receiver, JSObject::kElementsOffset)); |
// a3: elements array |
@@ -4088,7 +4089,7 @@ void KeyedStoreStubCompiler::GenerateStoreExternalArray( |
// have been verified by the caller to not be a smi. |
// Check that the key is a smi or a heap number convertible to a smi. |
- GenerateSmiKeyCheck(masm, key, t0, t1, f2, &miss_force_generic); |
+ GenerateSmiKeyCheck(masm, key, t0, t1, f2, f4, &miss_force_generic); |
__ lw(a3, FieldMemOperand(receiver, JSObject::kElementsOffset)); |
@@ -4477,7 +4478,7 @@ void KeyedLoadStubCompiler::GenerateLoadFastElement(MacroAssembler* masm) { |
// have been verified by the caller to not be a smi. |
// Check that the key is a smi or a heap number convertible to a smi. |
- GenerateSmiKeyCheck(masm, a0, t0, t1, f2, &miss_force_generic); |
+ GenerateSmiKeyCheck(masm, a0, t0, t1, f2, f4, &miss_force_generic); |
// Get the elements array. |
__ lw(a2, FieldMemOperand(a1, JSObject::kElementsOffset)); |
@@ -4528,7 +4529,7 @@ void KeyedLoadStubCompiler::GenerateLoadFastDoubleElement( |
// have been verified by the caller to not be a smi. |
// Check that the key is a smi or a heap number convertible to a smi. |
- GenerateSmiKeyCheck(masm, key_reg, t0, t1, f2, &miss_force_generic); |
+ GenerateSmiKeyCheck(masm, key_reg, t0, t1, f2, f4, &miss_force_generic); |
// Get the elements array. |
__ lw(elements_reg, |
@@ -4602,7 +4603,7 @@ void KeyedStoreStubCompiler::GenerateStoreFastElement( |
// have been verified by the caller to not be a smi. |
// Check that the key is a smi or a heap number convertible to a smi. |
- GenerateSmiKeyCheck(masm, key_reg, t0, t1, f2, &miss_force_generic); |
+ GenerateSmiKeyCheck(masm, key_reg, t0, t1, f2, f4, &miss_force_generic); |
if (IsFastSmiElementsKind(elements_kind)) { |
__ JumpIfNotSmi(value_reg, &transition_elements_kind); |
@@ -4769,7 +4770,7 @@ void KeyedStoreStubCompiler::GenerateStoreFastDoubleElement( |
// have been verified by the caller to not be a smi. |
// Check that the key is a smi or a heap number convertible to a smi. |
- GenerateSmiKeyCheck(masm, key_reg, t0, t1, f2, &miss_force_generic); |
+ GenerateSmiKeyCheck(masm, key_reg, t0, t1, f2, f4, &miss_force_generic); |
__ lw(elements_reg, |
FieldMemOperand(receiver_reg, JSObject::kElementsOffset)); |