| OLD | NEW |
| 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_X64 | 5 #if V8_TARGET_ARCH_X64 |
| 6 | 6 |
| 7 #include "src/code-factory.h" | 7 #include "src/code-factory.h" |
| 8 #include "src/codegen.h" | 8 #include "src/codegen.h" |
| 9 #include "src/deoptimizer.h" | 9 #include "src/deoptimizer.h" |
| 10 #include "src/full-codegen/full-codegen.h" | 10 #include "src/full-codegen/full-codegen.h" |
| (...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 610 // Open a frame scope to indicate that there is a frame on the stack. The | 610 // Open a frame scope to indicate that there is a frame on the stack. The |
| 611 // MANUAL indicates that the scope shouldn't actually generate code to set up | 611 // MANUAL indicates that the scope shouldn't actually generate code to set up |
| 612 // the frame (that is done below). | 612 // the frame (that is done below). |
| 613 FrameScope frame_scope(masm, StackFrame::MANUAL); | 613 FrameScope frame_scope(masm, StackFrame::MANUAL); |
| 614 __ pushq(rbp); // Caller's frame pointer. | 614 __ pushq(rbp); // Caller's frame pointer. |
| 615 __ movp(rbp, rsp); | 615 __ movp(rbp, rsp); |
| 616 __ Push(rsi); // Callee's context. | 616 __ Push(rsi); // Callee's context. |
| 617 __ Push(rdi); // Callee's JS function. | 617 __ Push(rdi); // Callee's JS function. |
| 618 __ Push(rdx); // Callee's new target. | 618 __ Push(rdx); // Callee's new target. |
| 619 | 619 |
| 620 // Push dispatch table pointer. |
| 621 __ Move(rax, ExternalReference::interpreter_dispatch_table_address( |
| 622 masm->isolate())); |
| 623 __ Push(rax); |
| 620 // Push zero for bytecode array offset. | 624 // Push zero for bytecode array offset. |
| 621 __ Push(Immediate(0)); | 625 __ Push(Immediate(0)); |
| 622 | 626 |
| 623 // Get the bytecode array from the function object and load the pointer to the | 627 // Get the bytecode array from the function object and load the pointer to the |
| 624 // first entry into edi (InterpreterBytecodeRegister). | 628 // first entry into edi (InterpreterBytecodeRegister). |
| 625 __ movp(rax, FieldOperand(rdi, JSFunction::kSharedFunctionInfoOffset)); | 629 __ movp(rax, FieldOperand(rdi, JSFunction::kSharedFunctionInfoOffset)); |
| 626 __ movp(kInterpreterBytecodeArrayRegister, | 630 __ movp(kInterpreterBytecodeArrayRegister, |
| 627 FieldOperand(rax, SharedFunctionInfo::kFunctionDataOffset)); | 631 FieldOperand(rax, SharedFunctionInfo::kFunctionDataOffset)); |
| 628 | 632 |
| 629 if (FLAG_debug_code) { | 633 if (FLAG_debug_code) { |
| (...skipping 2218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2848 __ ret(0); | 2852 __ ret(0); |
| 2849 } | 2853 } |
| 2850 | 2854 |
| 2851 | 2855 |
| 2852 #undef __ | 2856 #undef __ |
| 2853 | 2857 |
| 2854 } // namespace internal | 2858 } // namespace internal |
| 2855 } // namespace v8 | 2859 } // namespace v8 |
| 2856 | 2860 |
| 2857 #endif // V8_TARGET_ARCH_X64 | 2861 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |