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

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

Issue 1362383002: [Interpreter] Add CallRuntime support to the interpreter. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix arm32 debug build check errors. Created 5 years, 2 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 | « src/x64/builtins-x64.cc ('k') | src/x64/interface-descriptors-x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/x64/code-stubs-x64.cc
diff --git a/src/x64/code-stubs-x64.cc b/src/x64/code-stubs-x64.cc
index 0942b2fb3c1a85af5c9581a35c5936629eb9dd50..3a9ad53c0f28fc1965acc2bb474cbb3188407029 100644
--- a/src/x64/code-stubs-x64.cc
+++ b/src/x64/code-stubs-x64.cc
@@ -2268,6 +2268,9 @@ void CEntryStub::Generate(MacroAssembler* masm) {
// rbp: frame pointer of calling JS frame (restored after C call)
// rsp: stack pointer (restored after C call)
// rsi: current context (restored)
+ //
+ // If argv_in_register():
+ // r15: pointer to the first argument
ProfileEntryHookStub::MaybeCallEntryHook(masm);
@@ -2277,7 +2280,14 @@ void CEntryStub::Generate(MacroAssembler* masm) {
#else // _WIN64
int arg_stack_space = 0;
#endif // _WIN64
- __ EnterExitFrame(arg_stack_space, save_doubles());
+ if (argv_in_register()) {
+ DCHECK(!save_doubles());
+ __ EnterApiExitFrame(arg_stack_space);
+ // Move argc into r14 (argv is already in r15).
+ __ movp(r14, rax);
+ } else {
+ __ EnterExitFrame(arg_stack_space, save_doubles());
+ }
// rbx: pointer to builtin function (C callee-saved).
// rbp: frame pointer of exit frame (restored after C call).
@@ -2357,7 +2367,7 @@ void CEntryStub::Generate(MacroAssembler* masm) {
}
// Exit the JavaScript to C++ exit frame.
- __ LeaveExitFrame(save_doubles());
+ __ LeaveExitFrame(save_doubles(), !argv_in_register());
__ ret(0);
// Handling of exception.
« no previous file with comments | « src/x64/builtins-x64.cc ('k') | src/x64/interface-descriptors-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698