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

Side by Side Diff: src/arm/code-stubs-arm.cc

Issue 2090723005: [builtins] New frame type for exits to C++ builtins (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #if V8_TARGET_ARCH_ARM 5 #if V8_TARGET_ARCH_ARM
6 6
7 #include "src/code-stubs.h" 7 #include "src/code-stubs.h"
8 #include "src/api-arguments.h" 8 #include "src/api-arguments.h"
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/bootstrapper.h" 10 #include "src/bootstrapper.h"
(...skipping 932 matching lines...) Expand 10 before | Expand all | Expand 10 after
943 // Move argv into the correct register. 943 // Move argv into the correct register.
944 __ mov(r1, Operand(r2)); 944 __ mov(r1, Operand(r2));
945 } else { 945 } else {
946 // Compute the argv pointer in a callee-saved register. 946 // Compute the argv pointer in a callee-saved register.
947 __ add(r1, sp, Operand(r0, LSL, kPointerSizeLog2)); 947 __ add(r1, sp, Operand(r0, LSL, kPointerSizeLog2));
948 __ sub(r1, r1, Operand(kPointerSize)); 948 __ sub(r1, r1, Operand(kPointerSize));
949 } 949 }
950 950
951 // Enter the exit frame that transitions from JavaScript to C++. 951 // Enter the exit frame that transitions from JavaScript to C++.
952 FrameScope scope(masm, StackFrame::MANUAL); 952 FrameScope scope(masm, StackFrame::MANUAL);
953 __ EnterExitFrame(save_doubles()); 953 __ EnterExitFrame(save_doubles(), 0, is_builtin_exit()
954 ? StackFrame::BUILTIN_EXIT
955 : StackFrame::EXIT);
954 956
955 // Store a copy of argc in callee-saved registers for later. 957 // Store a copy of argc in callee-saved registers for later.
956 __ mov(r4, Operand(r0)); 958 __ mov(r4, Operand(r0));
957 959
958 // r0, r4: number of arguments including receiver (C callee-saved) 960 // r0, r4: number of arguments including receiver (C callee-saved)
959 // r1: pointer to the first argument (C callee-saved) 961 // r1: pointer to the first argument (C callee-saved)
960 // r5: pointer to builtin function (C callee-saved) 962 // r5: pointer to builtin function (C callee-saved)
961 963
962 int frame_alignment = MacroAssembler::ActivationFrameAlignment(); 964 int frame_alignment = MacroAssembler::ActivationFrameAlignment();
963 int frame_alignment_mask = frame_alignment - 1; 965 int frame_alignment_mask = frame_alignment - 1;
(...skipping 4375 matching lines...) Expand 10 before | Expand all | Expand 10 after
5339 CallApiFunctionAndReturn(masm, api_function_address, thunk_ref, 5341 CallApiFunctionAndReturn(masm, api_function_address, thunk_ref,
5340 kStackUnwindSpace, NULL, return_value_operand, NULL); 5342 kStackUnwindSpace, NULL, return_value_operand, NULL);
5341 } 5343 }
5342 5344
5343 #undef __ 5345 #undef __
5344 5346
5345 } // namespace internal 5347 } // namespace internal
5346 } // namespace v8 5348 } // namespace v8
5347 5349
5348 #endif // V8_TARGET_ARCH_ARM 5350 #endif // V8_TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « src/arm/builtins-arm.cc ('k') | src/arm/macro-assembler-arm.h » ('j') | src/builtins.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698