Index: src/mips/code-stubs-mips.cc |
diff --git a/src/mips/code-stubs-mips.cc b/src/mips/code-stubs-mips.cc |
index 6f7922526fe4521c4cc228d61a4565e70ac36eb7..c40cd81b893c58de1f3a32a4acfac740abd81eca 100644 |
--- a/src/mips/code-stubs-mips.cc |
+++ b/src/mips/code-stubs-mips.cc |
@@ -5363,15 +5363,19 @@ static void GenerateRecordCallTarget(MacroAssembler* masm) { |
// A monomorphic miss (i.e, here the cache is not uninitialized) goes |
// megamorphic. |
__ LoadRoot(at, Heap::kTheHoleValueRootIndex); |
- __ Branch(&done, eq, a3, Operand(at)); |
+ |
+ __ Branch(USE_DELAY_SLOT, &done, eq, a3, Operand(at)); |
+ // An uninitialized cache is patched with the function. |
+ // Store a1 in the delay slot. This may or may not get overwritten depending |
+ // on the result of the comparison. |
+ __ sw(a1, FieldMemOperand(a2, JSGlobalPropertyCell::kValueOffset)); |
+ |
// MegamorphicSentinel is an immortal immovable object (undefined) so no |
// write-barrier is needed. |
__ LoadRoot(at, Heap::kUndefinedValueRootIndex); |
__ sw(at, FieldMemOperand(a2, JSGlobalPropertyCell::kValueOffset)); |
__ Branch(&done); |
Michael Starzinger
2012/02/29 09:48:21
Removed this obsolete branch before landing.
|
- // An uninitialized cache is patched with the function. |
- __ sw(a1, FieldMemOperand(a2, JSGlobalPropertyCell::kValueOffset)); |
// No need for a write barrier here - cells are rescanned. |
__ bind(&done); |