| Index: src/mips/stub-cache-mips.cc
|
| diff --git a/src/mips/stub-cache-mips.cc b/src/mips/stub-cache-mips.cc
|
| index f8cf9704b1049d4efe812cc8f4036c016d3e366b..8325afe2f9a471906d22fbbd7325652a565b8528 100644
|
| --- a/src/mips/stub-cache-mips.cc
|
| +++ b/src/mips/stub-cache-mips.cc
|
| @@ -458,10 +458,20 @@ void StubCompiler::GenerateStoreField(MacroAssembler* masm,
|
| }
|
|
|
| if (!transition.is_null()) {
|
| - // Update the map of the object; no write barrier updating is
|
| - // needed because the map is never in new space.
|
| - __ li(t0, Operand(transition));
|
| - __ sw(t0, FieldMemOperand(receiver_reg, HeapObject::kMapOffset));
|
| + // Update the map of the object.
|
| + __ li(scratch, Operand(transition));
|
| + __ sw(scratch, FieldMemOperand(receiver_reg, HeapObject::kMapOffset));
|
| +
|
| + // Update the write barrier for the map field and pass the now unused
|
| + // name_reg as scratch register.
|
| + __ RecordWriteField(receiver_reg,
|
| + HeapObject::kMapOffset,
|
| + scratch,
|
| + name_reg,
|
| + kRAHasNotBeenSaved,
|
| + kDontSaveFPRegs,
|
| + OMIT_REMEMBERED_SET,
|
| + OMIT_SMI_CHECK);
|
| }
|
|
|
| // Adjust for the number of properties stored in the object. Even in the
|
|
|