Index: src/ic/arm/ic-compiler-arm.cc |
diff --git a/src/ic/arm/ic-compiler-arm.cc b/src/ic/arm/ic-compiler-arm.cc |
index 7bef56e94de091e68cdc02f0da296a925286b84f..bfab8dd3d419e3f5172dc72fa7eb778e82cce583 100644 |
--- a/src/ic/arm/ic-compiler-arm.cc |
+++ b/src/ic/arm/ic-compiler-arm.cc |
@@ -72,8 +72,8 @@ Handle<Code> PropertyICCompiler::CompilePolymorphic(TypeHandleList* types, |
Handle<Map> map = IC::TypeToMap(*type, isolate()); |
if (!map->is_deprecated()) { |
number_of_handled_maps++; |
- __ mov(ip, Operand(map)); |
- __ cmp(map_reg, ip); |
+ Handle<WeakCell> cell = Map::WeakCellForMap(map); |
+ __ CmpWeakValue(map_reg, cell, scratch2()); |
if (type->Is(HeapType::Number())) { |
DCHECK(!number_case.is_unused()); |
__ bind(&number_case); |
@@ -100,16 +100,18 @@ Handle<Code> PropertyICCompiler::CompileKeyedStorePolymorphic( |
__ JumpIfSmi(receiver(), &miss); |
int receiver_count = receiver_maps->length(); |
- __ ldr(scratch1(), FieldMemOperand(receiver(), HeapObject::kMapOffset)); |
+ Register map_reg = scratch1(); |
+ __ ldr(map_reg, FieldMemOperand(receiver(), HeapObject::kMapOffset)); |
for (int i = 0; i < receiver_count; ++i) { |
- __ mov(ip, Operand(receiver_maps->at(i))); |
- __ cmp(scratch1(), ip); |
+ Handle<WeakCell> cell = Map::WeakCellForMap(receiver_maps->at(i)); |
+ __ CmpWeakValue(map_reg, cell, scratch2()); |
if (transitioned_maps->at(i).is_null()) { |
__ Jump(handler_stubs->at(i), RelocInfo::CODE_TARGET, eq); |
} else { |
Label next_map; |
__ b(ne, &next_map); |
- __ mov(transition_map(), Operand(transitioned_maps->at(i))); |
+ Handle<WeakCell> cell = Map::WeakCellForMap(transitioned_maps->at(i)); |
+ __ LoadWeakValue(transition_map(), cell, &miss); |
__ Jump(handler_stubs->at(i), RelocInfo::CODE_TARGET, al); |
__ bind(&next_map); |
} |