Index: src/arm64/builtins-arm64.cc |
diff --git a/src/arm64/builtins-arm64.cc b/src/arm64/builtins-arm64.cc |
index d4b76046562abfa32422d074a2503ec54d3eec2a..aff2b675e5539c4ca19511b5240d6232f0b6dc3d 100644 |
--- a/src/arm64/builtins-arm64.cc |
+++ b/src/arm64/builtins-arm64.cc |
@@ -1015,8 +1015,12 @@ void Builtins::Generate_InterpreterEntryTrampoline(MacroAssembler* masm) { |
__ Assert(eq, kFunctionDataShouldBeBytecodeArrayOnInterpreterEntry); |
} |
- // Push new.target, bytecode array and zero for bytecode array offset. |
- __ Mov(x0, Operand(0)); |
+ // Load the initial bytecode offset. |
+ __ Mov(kInterpreterBytecodeOffsetRegister, |
+ Operand(BytecodeArray::kHeaderSize - kHeapObjectTag)); |
+ |
+ // Push new.target, bytecode array and Smi tagged bytecode array offset. |
+ __ SmiTag(x0, kInterpreterBytecodeOffsetRegister); |
__ Push(x3, kInterpreterBytecodeArrayRegister, x0); |
// Allocate the local and temporary register file on the stack. |
@@ -1046,12 +1050,8 @@ void Builtins::Generate_InterpreterEntryTrampoline(MacroAssembler* masm) { |
__ Bind(&loop_header); |
} |
- // Load accumulator, register file, bytecode offset, dispatch table into |
- // registers. |
+ // Load accumulator and dispatch table into registers. |
__ LoadRoot(kInterpreterAccumulatorRegister, Heap::kUndefinedValueRootIndex); |
- __ Add(x18, fp, Operand(InterpreterFrameConstants::kRegisterFileFromFp)); |
- __ Mov(kInterpreterBytecodeOffsetRegister, |
- Operand(BytecodeArray::kHeaderSize - kHeapObjectTag)); |
__ Mov(kInterpreterDispatchTableRegister, |
Operand(ExternalReference::interpreter_dispatch_table_address( |
masm->isolate()))); |