8255233: InterpreterRuntime::at_unwind should be a JRT_LEAF

Reviewed-by: coleenp, dholmes
This commit is contained in:
Erik Österlund 2020-10-28 14:14:51 +00:00
parent bbf0a31e9e
commit aaf4f690f0
3 changed files with 7 additions and 6 deletions

View file

@ -551,7 +551,9 @@ void InterpreterMacroAssembler::remove_activation(
br(Assembler::AL, fast_path); br(Assembler::AL, fast_path);
bind(slow_path); bind(slow_path);
push(state); push(state);
call_VM(noreg, CAST_FROM_FN_PTR(address, InterpreterRuntime::at_unwind)); set_last_Java_frame(esp, rfp, (address)pc(), rscratch1);
super_call_VM_leaf(CAST_FROM_FN_PTR(address, InterpreterRuntime::at_unwind), rthread);
reset_last_Java_frame(true);
pop(state); pop(state);
bind(fast_path); bind(fast_path);

View file

@ -1003,7 +1003,9 @@ void InterpreterMacroAssembler::remove_activation(
jmp(fast_path); jmp(fast_path);
bind(slow_path); bind(slow_path);
push(state); push(state);
call_VM(noreg, CAST_FROM_FN_PTR(address, InterpreterRuntime::at_unwind)); set_last_Java_frame(rthread, noreg, rbp, (address)pc());
super_call_VM_leaf(CAST_FROM_FN_PTR(address, InterpreterRuntime::at_unwind), rthread);
reset_last_Java_frame(rthread, true);
pop(state); pop(state);
NOT_LP64(get_thread(rthread);) // call_VM clobbered it, restore NOT_LP64(get_thread(rthread);) // call_VM clobbered it, restore
bind(fast_path); bind(fast_path);

View file

@ -1172,10 +1172,7 @@ JRT_ENTRY(void, InterpreterRuntime::at_safepoint(JavaThread* thread))
} }
JRT_END JRT_END
JRT_ENTRY(void, InterpreterRuntime::at_unwind(JavaThread* thread)) JRT_LEAF(void, InterpreterRuntime::at_unwind(JavaThread* thread))
// JRT_END does an implicit safepoint check, hence we are guaranteed to block
// if this is called during a safepoint
// This function is called by the interpreter when the return poll found a reason // This function is called by the interpreter when the return poll found a reason
// to call the VM. The reason could be that we are returning into a not yet safe // to call the VM. The reason could be that we are returning into a not yet safe
// to access frame. We handle that below. // to access frame. We handle that below.