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

Unified Diff: src/arm/code-stubs-arm.cc

Issue 7640016: Refactored DirectCEntryStub::GenerateCall a bit to make it clearer what's going on and added an A... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 9 years, 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/arm/code-stubs-arm.cc
===================================================================
--- src/arm/code-stubs-arm.cc (revision 8927)
+++ src/arm/code-stubs-arm.cc (working copy)
@@ -6315,14 +6315,8 @@
void DirectCEntryStub::GenerateCall(MacroAssembler* masm,
ExternalReference function) {
- __ mov(lr, Operand(reinterpret_cast<intptr_t>(GetCode().location()),
- RelocInfo::CODE_TARGET));
__ mov(r2, Operand(function));
- // Push return address (accessible to GC through exit frame pc).
- // Note that using pc with str is deprecated.
- __ add(ip, pc, Operand(4));
- __ str(ip, MemOperand(sp, 0));
- __ Jump(r2); // Call the api function.
+ GenerateCall(masm, r2);
}
@@ -6332,9 +6326,13 @@
RelocInfo::CODE_TARGET));
// Push return address (accessible to GC through exit frame pc).
// Note that using pc with str is deprecated.
- __ add(ip, pc, Operand(4));
+ Label start;
+ __ bind(&start);
+ __ add(ip, pc, Operand(Assembler::kInstrSize));
__ str(ip, MemOperand(sp, 0));
__ Jump(target); // Call the C++ function.
+ ASSERT_EQ(Assembler::kInstrSize + Assembler::kPcLoadDelta,
+ masm->SizeOfCodeGeneratedSince(&start));
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698