Index: src/mips/macro-assembler-mips.cc |
diff --git a/src/mips/macro-assembler-mips.cc b/src/mips/macro-assembler-mips.cc |
index 1a6bc216ccc9d72c5e060249a9ec1bd42f8396eb..6233b830e01107ec939a74441dbf15057b0a67d3 100644 |
--- a/src/mips/macro-assembler-mips.cc |
+++ b/src/mips/macro-assembler-mips.cc |
@@ -5290,13 +5290,21 @@ void MacroAssembler::EnsureNotWhite( |
void MacroAssembler::LoadInstanceDescriptors(Register map, |
- Register descriptors) { |
+ Register descriptors, |
+ Register scratch) { |
lw(descriptors, |
- FieldMemOperand(map, Map::kInstanceDescriptorsOrBitField3Offset)); |
- Label not_smi; |
- JumpIfNotSmi(descriptors, ¬_smi); |
+ FieldMemOperand(map, Map::kInstanceDescriptorsOrBackPointerOffset)); |
+ |
+ Label ok, fail; |
+ CheckMap(descriptors, |
+ scratch, |
+ isolate()->factory()->fixed_array_map(), |
+ &fail, |
+ DONT_DO_SMI_CHECK); |
+ jmp(&ok); |
+ bind(&fail); |
LoadRoot(descriptors, Heap::kEmptyDescriptorArrayRootIndex); |
- bind(¬_smi); |
+ bind(&ok); |
} |
@@ -5320,8 +5328,13 @@ void MacroAssembler::CheckEnumCache(Register null_value, Label* call_runtime) { |
// check for an enum cache. Leave the map in a2 for the subsequent |
// prototype load. |
lw(a2, FieldMemOperand(a1, HeapObject::kMapOffset)); |
- lw(a3, FieldMemOperand(a2, Map::kInstanceDescriptorsOrBitField3Offset)); |
- JumpIfSmi(a3, call_runtime); |
+ lw(a3, FieldMemOperand(a2, Map::kInstanceDescriptorsOrBackPointerOffset)); |
+ |
+ CheckMap(a3, |
+ t3, |
+ isolate()->factory()->fixed_array_map(), |
+ call_runtime, |
+ DONT_DO_SMI_CHECK); |
// Check that there is an enum cache in the non-empty instance |
// descriptors (a3). This is the case if the next enumeration |