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

Unified Diff: runtime/vm/stub_code_mips.cc

Issue 517383005: VM: Clean up generated code for NoSuchMethod invocation of closures. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 3 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
Index: runtime/vm/stub_code_mips.cc
===================================================================
--- runtime/vm/stub_code_mips.cc (revision 39693)
+++ runtime/vm/stub_code_mips.cc (working copy)
@@ -1299,7 +1299,6 @@
// Input parameters:
// RA : return address.
// SP : address of last argument.
-// S5: inline cache data object.
// S4: arguments descriptor array.
void StubCode::GenerateCallNoSuchMethodFunctionStub(Assembler* assembler) {
__ EnterStubFrame();
@@ -1314,19 +1313,19 @@
// Push the receiver.
// Push IC data object.
// Push arguments descriptor array.
- __ addiu(SP, SP, Immediate(-4 * kWordSize));
+ const intptr_t kNumArgs = 3;
+ __ addiu(SP, SP, Immediate(-kNumArgs * kWordSize));
__ LoadImmediate(TMP, reinterpret_cast<intptr_t>(Object::null()));
- __ sw(TMP, Address(SP, 3 * kWordSize));
- __ sw(T6, Address(SP, 2 * kWordSize));
- __ sw(S5, Address(SP, 1 * kWordSize));
+ __ sw(TMP, Address(SP, 2 * kWordSize));
+ __ sw(T6, Address(SP, 1 * kWordSize));
__ sw(S4, Address(SP, 0 * kWordSize));
// A1: Smi-tagged arguments array length.
PushArgumentsArray(assembler);
- __ CallRuntime(kInvokeNoSuchMethodFunctionRuntimeEntry, 4);
+ __ CallRuntime(kInvokeNoSuchMethodFunctionRuntimeEntry, kNumArgs);
- __ lw(V0, Address(SP, 4 * kWordSize)); // Get result into V0.
+ __ lw(V0, Address(SP, kNumArgs * kWordSize)); // Get result into V0.
__ LeaveStubFrameAndReturn();
}

Powered by Google App Engine
This is Rietveld 408576698