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

Unified Diff: runtime/vm/stub_code_arm64.cc

Issue 311963002: In class Function replace current code field with current instruction field, that way we save one l… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 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/stub_code_arm.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_arm64.cc
===================================================================
--- runtime/vm/stub_code_arm64.cc (revision 36916)
+++ runtime/vm/stub_code_arm64.cc (working copy)
@@ -598,8 +598,7 @@
__ LeaveStubFrame();
// Tail-call to target function.
- __ LoadFieldFromOffset(R2, R0, Function::code_offset(), kNoPP);
- __ LoadFieldFromOffset(R2, R2, Code::instructions_offset(), kNoPP);
+ __ LoadFieldFromOffset(R2, R0, Function::instructions_offset(), kNoPP);
__ AddImmediate(R2, R2, Instructions::HeaderSize() - kHeapObjectTag, PP);
__ br(R2);
}
@@ -1478,8 +1477,7 @@
__ Bind(&call_target_function);
// R0: target function.
- __ LoadFieldFromOffset(R2, R0, Function::code_offset(), kNoPP);
- __ LoadFieldFromOffset(R2, R2, Code::instructions_offset(), kNoPP);
+ __ LoadFieldFromOffset(R2, R0, Function::instructions_offset(), kNoPP);
__ AddImmediate(
R2, R2, Instructions::HeaderSize() - kHeapObjectTag, kNoPP);
__ br(R2);
@@ -1602,11 +1600,10 @@
// Get function and call it, if possible.
__ LoadFromOffset(R0, R6, target_offset, kNoPP);
- __ LoadFieldFromOffset(R2, R0, Function::code_offset(), kNoPP);
+ __ LoadFieldFromOffset(R2, R0, Function::instructions_offset(), kNoPP);
// R0: function.
- // R2: target code.
- __ LoadFieldFromOffset(R2, R2, Code::instructions_offset(), kNoPP);
+ // R2: target instructons.
__ AddImmediate(
R2, R2, Instructions::HeaderSize() - kHeapObjectTag, kNoPP);
__ br(R2);
@@ -1636,8 +1633,7 @@
__ Pop(R5); // Restore IC Data.
__ LeaveStubFrame();
- __ LoadFieldFromOffset(R2, R0, Function::code_offset(), kNoPP);
- __ LoadFieldFromOffset(R2, R2, Code::instructions_offset(), kNoPP);
+ __ LoadFieldFromOffset(R2, R0, Function::instructions_offset(), kNoPP);
__ AddImmediate(
R2, R2, Instructions::HeaderSize() - kHeapObjectTag, kNoPP);
__ br(R2);
« no previous file with comments | « runtime/vm/stub_code_arm.cc ('k') | runtime/vm/stub_code_ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698