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

Unified Diff: runtime/vm/stub_code_mips.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_ia32.cc ('k') | runtime/vm/stub_code_x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/stub_code_mips.cc
===================================================================
--- runtime/vm/stub_code_mips.cc (revision 36916)
+++ runtime/vm/stub_code_mips.cc (working copy)
@@ -670,8 +670,7 @@
__ LeaveStubFrame();
- __ lw(T2, FieldAddress(T0, Function::code_offset()));
- __ lw(T2, FieldAddress(T2, Code::instructions_offset()));
+ __ lw(T2, FieldAddress(T0, Function::instructions_offset()));
__ AddImmediate(T2, Instructions::HeaderSize() - kHeapObjectTag);
__ jr(T2);
}
@@ -1570,8 +1569,7 @@
// T0 <- T3: Target function.
__ mov(T0, T3);
Label is_compiled;
- __ lw(T4, FieldAddress(T0, Function::code_offset()));
- __ lw(T4, FieldAddress(T4, Code::instructions_offset()));
+ __ lw(T4, FieldAddress(T0, Function::instructions_offset()));
__ AddImmediate(T4, Instructions::HeaderSize() - kHeapObjectTag);
__ jr(T4);
@@ -1715,10 +1713,9 @@
// Get function and call it, if possible.
__ lw(T0, Address(T0, target_offset));
- __ lw(T4, FieldAddress(T0, Function::code_offset()));
+ __ lw(T4, FieldAddress(T0, Function::instructions_offset()));
- // T4: target code.
- __ lw(T4, FieldAddress(T4, Code::instructions_offset()));
+ // T4: target instructions.
__ AddImmediate(T4, Instructions::HeaderSize() - kHeapObjectTag);
__ jr(T4);
}
@@ -1748,8 +1745,7 @@
__ addiu(SP, SP, Immediate(3 * kWordSize));
__ LeaveStubFrame();
- __ lw(T2, FieldAddress(T0, Function::code_offset()));
- __ lw(T2, FieldAddress(T2, Code::instructions_offset()));
+ __ lw(T2, FieldAddress(T0, Function::instructions_offset()));
__ AddImmediate(T2, Instructions::HeaderSize() - kHeapObjectTag);
__ jr(T2);
}
« no previous file with comments | « runtime/vm/stub_code_ia32.cc ('k') | runtime/vm/stub_code_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698