Index: src/arm64/builtins-arm64.cc |
diff --git a/src/arm64/builtins-arm64.cc b/src/arm64/builtins-arm64.cc |
index 0840eb952b2a45cab665b0715820e6d3701da433..337a090ad351adfe3e002f80bf22fcc5023aec42 100644 |
--- a/src/arm64/builtins-arm64.cc |
+++ b/src/arm64/builtins-arm64.cc |
@@ -997,12 +997,6 @@ void Builtins::Generate_InterpreterEntryTrampoline(MacroAssembler* masm) { |
__ Push(lr, fp, cp, x1); |
__ Add(fp, jssp, StandardFrameConstants::kFixedFrameSizeFromFp); |
- // Push dispatch table pointer. |
- __ Mov(x0, Operand(0)); |
- __ Mov(x2, Operand(ExternalReference::interpreter_dispatch_table_address( |
- masm->isolate()))); |
- __ Push(x3, x2, x0); |
- |
// Get the bytecode array from the function object and load the pointer to the |
// first entry into kInterpreterBytecodeRegister. |
__ Ldr(x0, FieldMemOperand(x1, JSFunction::kSharedFunctionInfoOffset)); |
@@ -1018,6 +1012,10 @@ void Builtins::Generate_InterpreterEntryTrampoline(MacroAssembler* masm) { |
__ Assert(eq, kFunctionDataShouldBeBytecodeArrayOnInterpreterEntry); |
} |
+ // Push new.target, bytecode array and zero for bytecode array offset. |
+ __ Mov(x0, Operand(0)); |
+ __ Push(x3, kInterpreterBytecodeArrayRegister, x0); |
+ |
// Allocate the local and temporary register file on the stack. |
{ |
// Load frame size from the BytecodeArray object. |
@@ -1058,8 +1056,9 @@ void Builtins::Generate_InterpreterEntryTrampoline(MacroAssembler* masm) { |
Operand(InterpreterFrameConstants::kRegisterFilePointerFromFp)); |
__ Mov(kInterpreterBytecodeOffsetRegister, |
Operand(BytecodeArray::kHeaderSize - kHeapObjectTag)); |
- __ Ldr(kInterpreterDispatchTableRegister, |
- MemOperand(fp, InterpreterFrameConstants::kDispatchTableFromFp)); |
+ __ Mov(kInterpreterDispatchTableRegister, |
+ Operand(ExternalReference::interpreter_dispatch_table_address( |
+ masm->isolate()))); |
// Dispatch to the first bytecode handler for the function. |
__ Ldrb(x1, MemOperand(kInterpreterBytecodeArrayRegister, |
@@ -1110,12 +1109,10 @@ static void Generate_EnterBytecodeDispatch(MacroAssembler* masm) { |
InterpreterFrameConstants::kContextFromRegisterPointer)); |
// Get the bytecode array pointer from the frame. |
- __ Ldr(x1, |
- MemOperand(kInterpreterRegisterFileRegister, |
- InterpreterFrameConstants::kFunctionFromRegisterPointer)); |
- __ Ldr(x1, FieldMemOperand(x1, JSFunction::kSharedFunctionInfoOffset)); |
- __ Ldr(kInterpreterBytecodeArrayRegister, |
- FieldMemOperand(x1, SharedFunctionInfo::kFunctionDataOffset)); |
+ __ Ldr( |
+ kInterpreterBytecodeArrayRegister, |
+ MemOperand(kInterpreterRegisterFileRegister, |
+ InterpreterFrameConstants::kBytecodeArrayFromRegisterPointer)); |
if (FLAG_debug_code) { |
// Check function data field is actually a BytecodeArray object. |