| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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_X64 | 5 #if V8_TARGET_ARCH_X64 |
| 6 | 6 |
| 7 #include "src/bootstrapper.h" | 7 #include "src/bootstrapper.h" |
| 8 #include "src/code-stubs.h" | 8 #include "src/code-stubs.h" |
| 9 #include "src/codegen.h" | 9 #include "src/codegen.h" |
| 10 #include "src/ic/handler-compiler.h" | 10 #include "src/ic/handler-compiler.h" |
| (...skipping 5202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5213 | 5213 |
| 5214 Register callee = rdi; | 5214 Register callee = rdi; |
| 5215 Register call_data = rbx; | 5215 Register call_data = rbx; |
| 5216 Register holder = rcx; | 5216 Register holder = rcx; |
| 5217 Register api_function_address = rdx; | 5217 Register api_function_address = rdx; |
| 5218 Register context = rsi; | 5218 Register context = rsi; |
| 5219 Register return_address = r8; | 5219 Register return_address = r8; |
| 5220 | 5220 |
| 5221 typedef FunctionCallbackArguments FCA; | 5221 typedef FunctionCallbackArguments FCA; |
| 5222 | 5222 |
| 5223 STATIC_ASSERT(FCA::kContextSaveIndex == 5); | 5223 STATIC_ASSERT(FCA::kContextSaveIndex == 6); |
| 5224 STATIC_ASSERT(FCA::kCalleeIndex == 5); |
| 5224 STATIC_ASSERT(FCA::kDataIndex == 4); | 5225 STATIC_ASSERT(FCA::kDataIndex == 4); |
| 5225 STATIC_ASSERT(FCA::kReturnValueOffset == 3); | 5226 STATIC_ASSERT(FCA::kReturnValueOffset == 3); |
| 5226 STATIC_ASSERT(FCA::kReturnValueDefaultValueIndex == 2); | 5227 STATIC_ASSERT(FCA::kReturnValueDefaultValueIndex == 2); |
| 5227 STATIC_ASSERT(FCA::kIsolateIndex == 1); | 5228 STATIC_ASSERT(FCA::kIsolateIndex == 1); |
| 5228 STATIC_ASSERT(FCA::kHolderIndex == 0); | 5229 STATIC_ASSERT(FCA::kHolderIndex == 0); |
| 5229 STATIC_ASSERT(FCA::kArgsLength == 6); | 5230 STATIC_ASSERT(FCA::kArgsLength == 7); |
| 5230 | 5231 |
| 5231 DCHECK(argc.is_immediate() || rax.is(argc.reg())); | 5232 DCHECK(argc.is_immediate() || rax.is(argc.reg())); |
| 5232 | 5233 |
| 5233 __ PopReturnAddressTo(return_address); | 5234 __ PopReturnAddressTo(return_address); |
| 5234 | 5235 |
| 5235 // context save | 5236 // context save |
| 5236 __ Push(context); | 5237 __ Push(context); |
| 5237 | 5238 |
| 5239 // callee |
| 5240 __ Push(callee); |
| 5241 |
| 5238 // call data | 5242 // call data |
| 5239 __ Push(call_data); | 5243 __ Push(call_data); |
| 5240 Register scratch = call_data; | 5244 Register scratch = call_data; |
| 5241 if (!call_data_undefined) { | 5245 if (!call_data_undefined) { |
| 5242 __ LoadRoot(scratch, Heap::kUndefinedValueRootIndex); | 5246 __ LoadRoot(scratch, Heap::kUndefinedValueRootIndex); |
| 5243 } | 5247 } |
| 5244 // return value | 5248 // return value |
| 5245 __ Push(scratch); | 5249 __ Push(scratch); |
| 5246 // return value default | 5250 // return value default |
| 5247 __ Push(scratch); | 5251 __ Push(scratch); |
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5399 kStackSpace, nullptr, return_value_operand, NULL); | 5403 kStackSpace, nullptr, return_value_operand, NULL); |
| 5400 } | 5404 } |
| 5401 | 5405 |
| 5402 | 5406 |
| 5403 #undef __ | 5407 #undef __ |
| 5404 | 5408 |
| 5405 } // namespace internal | 5409 } // namespace internal |
| 5406 } // namespace v8 | 5410 } // namespace v8 |
| 5407 | 5411 |
| 5408 #endif // V8_TARGET_ARCH_X64 | 5412 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |