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

Unified Diff: runtime/vm/runtime_entry_arm64.cc

Issue 311413002: Changes for running tests on arm64 hardware. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 6 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/profiler.cc ('k') | runtime/vm/stub_code_arm64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/runtime_entry_arm64.cc
===================================================================
--- runtime/vm/runtime_entry_arm64.cc (revision 37032)
+++ runtime/vm/runtime_entry_arm64.cc (working copy)
@@ -40,10 +40,18 @@
if (is_leaf()) {
ASSERT(argument_count == this->argument_count());
ExternalLabel label(entry);
- // Cache the stack pointer in a callee-saved register.
+ // Since we are entering C++ code, we must restore the C stack pointer from
+ // the stack limit to an aligned value nearer to the top of the stack.
+ // We cache the Dart stack pointer and the stack limit in callee-saved
+ // registers, then align and call, restoring CSP and SP on return from the
+ // call.
+ __ mov(R25, CSP);
__ mov(R26, SP);
regis 2014/06/05 17:55:34 R25 and R26 are callee-saved and will thus be pres
zra 2014/06/05 18:35:53 Before IL instructions with a kCall LocationSummar
+ __ ReserveAlignedFrameSpace(0);
+ __ mov(CSP, SP);
__ BranchLink(&label, kNoPP);
__ mov(SP, R26);
+ __ mov(CSP, R25);
} else {
// Argument count is not checked here, but in the runtime entry for a more
// informative error message.
« no previous file with comments | « runtime/vm/profiler.cc ('k') | runtime/vm/stub_code_arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698