Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(201)

Unified Diff: runtime/vm/stub_code_arm.cc

Issue 14925005: Remove stack_frame_<arch>.cc files. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/stack_frame_x64.cc ('k') | runtime/vm/stub_code_ia32.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/stub_code_arm.cc
===================================================================
--- runtime/vm/stub_code_arm.cc (revision 22469)
+++ runtime/vm/stub_code_arm.cc (working copy)
@@ -241,7 +241,7 @@
// Input parameters:
// R2: smi-tagged argument count, may be zero.
-// FP[kLastParamSlotIndex]: last argument.
+// FP[kParamEndSlotFromFp + 1]: last argument.
static void PushArgumentsArray(Assembler* assembler) {
// Allocate array to store arguments of caller.
__ LoadImmediate(R1, reinterpret_cast<intptr_t>(Object::null()));
@@ -252,7 +252,7 @@
// R2: smi-tagged argument count, may be zero (was preserved by the stub).
__ Push(R0); // Array is in R0 and on top of stack.
__ add(R1, FP, ShifterOperand(R2, LSL, 1));
- __ AddImmediate(R1, (kLastParamSlotIndex - 1) * kWordSize);
+ __ AddImmediate(R1, kParamEndSlotFromFp * kWordSize);
__ AddImmediate(R3, R0, Array::data_offset() - kHeapObjectTag);
// R1: address of first argument on stack.
// R3: address of first argument in array.
@@ -279,7 +279,7 @@
// Load the receiver.
__ ldr(R2, FieldAddress(R4, ArgumentsDescriptor::count_offset()));
__ add(IP, FP, ShifterOperand(R2, LSL, 1)); // R2 is Smi.
- __ ldr(R6, Address(IP, (kLastParamSlotIndex - 1) * kWordSize));
+ __ ldr(R6, Address(IP, kParamEndSlotFromFp * kWordSize));
// Push space for the return value.
// Push the receiver.
@@ -692,16 +692,18 @@
// Save the old Context pointer. Use R4 as a temporary register.
// Note that VisitObjectPointers will find this saved Context pointer during
// GC marking, since it traverses any information between SP and
- // FP - kExitLinkOffsetInEntryFrame.
+ // FP - kExitLinkSlotFromEntryFp.
// EntryFrame::SavedContext reads the context saved in this frame.
__ LoadFromOffset(kLoadWord, R4, R8, Isolate::top_context_offset());
- // The constants kSavedContextOffsetInEntryFrame and
- // kExitLinkOffsetInEntryFrame must be kept in sync with the code below.
+ // The constants kSavedContextSlotFromEntryFp and
+ // kExitLinkSlotFromEntryFp must be kept in sync with the code below.
+ ASSERT(kExitLinkSlotFromEntryFp == -9);
+ ASSERT(kSavedContextSlotFromEntryFp == -10);
__ PushList((1 << R4) | (1 << R5));
// The stack pointer is restored after the call to this location.
- const intptr_t kSavedContextOffsetInEntryFrame = -10 * kWordSize;
+ const intptr_t kSavedContextSlotFromEntryFp = -10 * kWordSize;
// Load arguments descriptor array into R4, which is passed to Dart code.
__ ldr(R4, Address(R1, VMHandles::kOffsetOfRawPtrInHandle));
@@ -737,7 +739,7 @@
__ ldr(CTX, Address(CTX, VMHandles::kOffsetOfRawPtrInHandle));
// Get rid of arguments pushed on the stack.
- __ AddImmediate(SP, FP, kSavedContextOffsetInEntryFrame);
+ __ AddImmediate(SP, FP, kSavedContextSlotFromEntryFp);
// Load Isolate pointer from Context structure into CTX. Drop Context.
__ ldr(CTX, FieldAddress(CTX, Context::isolate_offset()));
« no previous file with comments | « runtime/vm/stack_frame_x64.cc ('k') | runtime/vm/stub_code_ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698