OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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_PPC | 5 #if V8_TARGET_ARCH_PPC |
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 910 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
921 int arg_stack_space = 1; | 921 int arg_stack_space = 1; |
922 | 922 |
923 // Pass buffer for return value on stack if necessary | 923 // Pass buffer for return value on stack if necessary |
924 bool needs_return_buffer = | 924 bool needs_return_buffer = |
925 result_size() > 2 || | 925 result_size() > 2 || |
926 (result_size() == 2 && !ABI_RETURNS_OBJECT_PAIRS_IN_REGS); | 926 (result_size() == 2 && !ABI_RETURNS_OBJECT_PAIRS_IN_REGS); |
927 if (needs_return_buffer) { | 927 if (needs_return_buffer) { |
928 arg_stack_space += result_size(); | 928 arg_stack_space += result_size(); |
929 } | 929 } |
930 | 930 |
931 __ EnterExitFrame(save_doubles(), arg_stack_space); | 931 __ EnterExitFrame(save_doubles(), arg_stack_space, is_builtin_exit() |
| 932 ? StackFrame::BUILTIN_EXIT |
| 933 : StackFrame::EXIT); |
932 | 934 |
933 // Store a copy of argc in callee-saved registers for later. | 935 // Store a copy of argc in callee-saved registers for later. |
934 __ mr(r14, r3); | 936 __ mr(r14, r3); |
935 | 937 |
936 // r3, r14: number of arguments including receiver (C callee-saved) | 938 // r3, r14: number of arguments including receiver (C callee-saved) |
937 // r4: pointer to the first argument | 939 // r4: pointer to the first argument |
938 // r15: pointer to builtin function (C callee-saved) | 940 // r15: pointer to builtin function (C callee-saved) |
939 | 941 |
940 // Result returned in registers or stack, depending on result size and ABI. | 942 // Result returned in registers or stack, depending on result size and ABI. |
941 | 943 |
(...skipping 4549 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5491 fp, (PropertyCallbackArguments::kReturnValueOffset + 3) * kPointerSize); | 5493 fp, (PropertyCallbackArguments::kReturnValueOffset + 3) * kPointerSize); |
5492 CallApiFunctionAndReturn(masm, api_function_address, thunk_ref, | 5494 CallApiFunctionAndReturn(masm, api_function_address, thunk_ref, |
5493 kStackUnwindSpace, NULL, return_value_operand, NULL); | 5495 kStackUnwindSpace, NULL, return_value_operand, NULL); |
5494 } | 5496 } |
5495 | 5497 |
5496 #undef __ | 5498 #undef __ |
5497 } // namespace internal | 5499 } // namespace internal |
5498 } // namespace v8 | 5500 } // namespace v8 |
5499 | 5501 |
5500 #endif // V8_TARGET_ARCH_PPC | 5502 #endif // V8_TARGET_ARCH_PPC |
OLD | NEW |