EmitX64::EmitTerminalInterpret: Restore RSP before CALL
This commit is contained in:
parent
e5f6450a24
commit
421ab344ad
1 changed files with 1 additions and 0 deletions
|
@ -430,6 +430,7 @@ void EmitX64::EmitTerminalInterpret(IR::Term::Interpret terminal, Arm::LocationD
|
||||||
code->MOV(64, R(ABI_PARAM1), Imm64(terminal.next.arm_pc));
|
code->MOV(64, R(ABI_PARAM1), Imm64(terminal.next.arm_pc));
|
||||||
code->MOV(64, R(ABI_PARAM2), Imm64(reinterpret_cast<u64>(jit_interface)));
|
code->MOV(64, R(ABI_PARAM2), Imm64(reinterpret_cast<u64>(jit_interface)));
|
||||||
code->MOV(32, MJitStateReg(Arm::Reg::PC), R(ABI_PARAM1));
|
code->MOV(32, MJitStateReg(Arm::Reg::PC), R(ABI_PARAM1));
|
||||||
|
code->MOV(64, R(RSP), MDisp(R15, offsetof(JitState, save_host_RSP)));
|
||||||
code->CALL(reinterpret_cast<void*>(cb.InterpreterFallback));
|
code->CALL(reinterpret_cast<void*>(cb.InterpreterFallback));
|
||||||
code->JMP(routines->RunCodeReturnAddress(), true); // TODO: Check cycles
|
code->JMP(routines->RunCodeReturnAddress(), true); // TODO: Check cycles
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue