| Index: src/arm64/builtins-arm64.cc
|
| diff --git a/src/arm64/builtins-arm64.cc b/src/arm64/builtins-arm64.cc
|
| index 9c50471b7cc92ea5e877084b61b421f7eba791fa..85132a17a10f0c9f2f93b2695e62be4408221f0a 100644
|
| --- a/src/arm64/builtins-arm64.cc
|
| +++ b/src/arm64/builtins-arm64.cc
|
| @@ -1018,25 +1018,7 @@ void Builtins::Generate_InterpreterExitTrampoline(MacroAssembler* masm) {
|
| }
|
|
|
|
|
| -static void Generate_InterpreterNotifyDeoptimizedHelper(
|
| - MacroAssembler* masm, Deoptimizer::BailoutType type) {
|
| - // Enter an internal frame.
|
| - {
|
| - FrameScope scope(masm, StackFrame::INTERNAL);
|
| - __ Push(kInterpreterAccumulatorRegister); // Save accumulator register.
|
| -
|
| - // Pass the deoptimization type to the runtime system.
|
| - __ Mov(x1, Operand(Smi::FromInt(static_cast<int>(type))));
|
| - __ Push(x1);
|
| - __ CallRuntime(Runtime::kNotifyDeoptimized);
|
| -
|
| - __ Pop(kInterpreterAccumulatorRegister); // Restore accumulator register.
|
| - // Tear down internal frame.
|
| - }
|
| -
|
| - // Drop state (we don't use this for interpreter deopts).
|
| - __ Drop(1);
|
| -
|
| +static void Generate_EnterBytecodeDispatch(MacroAssembler* masm) {
|
| // Initialize register file register and dispatch table register.
|
| __ Add(kInterpreterRegisterFileRegister, fp,
|
| Operand(InterpreterFrameConstants::kRegisterFilePointerFromFp));
|
| @@ -1086,6 +1068,30 @@ static void Generate_InterpreterNotifyDeoptimizedHelper(
|
| }
|
|
|
|
|
| +static void Generate_InterpreterNotifyDeoptimizedHelper(
|
| + MacroAssembler* masm, Deoptimizer::BailoutType type) {
|
| + // Enter an internal frame.
|
| + {
|
| + FrameScope scope(masm, StackFrame::INTERNAL);
|
| + __ Push(kInterpreterAccumulatorRegister); // Save accumulator register.
|
| +
|
| + // Pass the deoptimization type to the runtime system.
|
| + __ Mov(x1, Operand(Smi::FromInt(static_cast<int>(type))));
|
| + __ Push(x1);
|
| + __ CallRuntime(Runtime::kNotifyDeoptimized);
|
| +
|
| + __ Pop(kInterpreterAccumulatorRegister); // Restore accumulator register.
|
| + // Tear down internal frame.
|
| + }
|
| +
|
| + // Drop state (we don't use this for interpreter deopts).
|
| + __ Drop(1);
|
| +
|
| + // Enter the bytecode dispatch.
|
| + Generate_EnterBytecodeDispatch(masm);
|
| +}
|
| +
|
| +
|
| void Builtins::Generate_InterpreterNotifyDeoptimized(MacroAssembler* masm) {
|
| Generate_InterpreterNotifyDeoptimizedHelper(masm, Deoptimizer::EAGER);
|
| }
|
| @@ -1101,6 +1107,11 @@ void Builtins::Generate_InterpreterNotifyLazyDeoptimized(MacroAssembler* masm) {
|
| }
|
|
|
|
|
| +void Builtins::Generate_InterpreterEnterExceptionHandler(MacroAssembler* masm) {
|
| + Generate_EnterBytecodeDispatch(masm);
|
| +}
|
| +
|
| +
|
| void Builtins::Generate_CompileLazy(MacroAssembler* masm) {
|
| CallRuntimePassFunction(masm, Runtime::kCompileLazy);
|
| GenerateTailCallToReturnedCode(masm);
|
|
|