Index: runtime/vm/intrinsifier_arm.cc |
diff --git a/runtime/vm/intrinsifier_arm.cc b/runtime/vm/intrinsifier_arm.cc |
index b053d0f4ae5cf36330d2c8ca8906f4c7a878ab09..6320d8c039b1e3f468bbd3eead3274c46c8e6e36 100644 |
--- a/runtime/vm/intrinsifier_arm.cc |
+++ b/runtime/vm/intrinsifier_arm.cc |
@@ -172,9 +172,8 @@ void Intrinsifier::GrowableArray_add(Assembler* assembler) { |
sizeof(Raw##type_name) + kObjectAlignment - 1; \ |
__ AddImmediate(R2, fixed_size_plus_alignment_padding); \ |
__ bic(R2, R2, Operand(kObjectAlignment - 1)); \ |
- Heap::Space space = Heap::kNew; \ |
- __ ldr(R3, Address(THR, Thread::heap_offset())); \ |
- __ ldr(R0, Address(R3, Heap::TopOffset(space))); \ |
+ NOT_IN_PRODUCT(Heap::Space space = Heap::kNew); \ |
+ __ ldr(R0, Address(THR, Thread::top_offset())); \ |
\ |
/* R2: allocation size. */ \ |
__ adds(R1, R0, Operand(R2)); \ |
@@ -184,15 +183,14 @@ void Intrinsifier::GrowableArray_add(Assembler* assembler) { |
/* R0: potential new object start. */ \ |
/* R1: potential next object start. */ \ |
/* R2: allocation size. */ \ |
- /* R3: heap. */ \ |
- __ ldr(IP, Address(R3, Heap::EndOffset(space))); \ |
+ __ ldr(IP, Address(THR, Thread::end_offset())); \ |
__ cmp(R1, Operand(IP)); \ |
__ b(&fall_through, CS); \ |
\ |
/* Successfully allocated the object(s), now update top to point to */ \ |
/* next object start and initialize the object. */ \ |
NOT_IN_PRODUCT(__ LoadAllocationStatsAddress(R4, cid)); \ |
- __ str(R1, Address(R3, Heap::TopOffset(space))); \ |
+ __ str(R1, Address(THR, Thread::top_offset())); \ |
__ AddImmediate(R0, kHeapObjectTag); \ |
/* Initialize the tags. */ \ |
/* R0: new object start as a tagged pointer. */ \ |
@@ -1927,9 +1925,8 @@ static void TryAllocateOnebyteString(Assembler* assembler, |
__ bic(length_reg, length_reg, Operand(kObjectAlignment - 1)); |
const intptr_t cid = kOneByteStringCid; |
- Heap::Space space = Heap::kNew; |
- __ ldr(R3, Address(THR, Thread::heap_offset())); |
- __ ldr(R0, Address(R3, Heap::TopOffset(space))); |
+ NOT_IN_PRODUCT(Heap::Space space = Heap::kNew); |
+ __ ldr(R0, Address(THR, Thread::top_offset())); |
// length_reg: allocation size. |
__ adds(R1, R0, Operand(length_reg)); |
@@ -1939,15 +1936,14 @@ static void TryAllocateOnebyteString(Assembler* assembler, |
// R0: potential new object start. |
// R1: potential next object start. |
// R2: allocation size. |
- // R3: heap. |
- __ ldr(NOTFP, Address(R3, Heap::EndOffset(space))); |
+ __ ldr(NOTFP, Address(THR, Thread::end_offset())); |
__ cmp(R1, Operand(NOTFP)); |
__ b(&fail, CS); |
// Successfully allocated the object(s), now update top to point to |
// next object start and initialize the object. |
NOT_IN_PRODUCT(__ LoadAllocationStatsAddress(R4, cid)); |
- __ str(R1, Address(R3, Heap::TopOffset(space))); |
+ __ str(R1, Address(THR, Thread::top_offset())); |
__ AddImmediate(R0, kHeapObjectTag); |
// Initialize the tags. |