8268368: Adopt cast notation for JavaThread conversions

Reviewed-by: dholmes, stefank
This commit is contained in:
Guoxiong Li 2021-06-23 02:21:24 +00:00 committed by David Holmes
parent b6cfca8a89
commit cd678a383f
64 changed files with 139 additions and 145 deletions

View file

@ -561,7 +561,7 @@ void vm_exit(int code) {
// Historically there must have been some exit path for which
// that was not the case and so we set it explicitly - even
// though we no longer know what that path may be.
thread->as_Java_thread()->set_thread_state(_thread_in_vm);
JavaThread::cast(thread)->set_thread_state(_thread_in_vm);
}
// Fire off a VM_Exit operation to bring VM to a safepoint and exit
@ -609,7 +609,7 @@ void vm_perform_shutdown_actions() {
if (thread != NULL && thread->is_Java_thread()) {
// We are leaving the VM, set state to native (in case any OS exit
// handlers call back to the VM)
JavaThread* jt = thread->as_Java_thread();
JavaThread* jt = JavaThread::cast(thread);
// Must always be walkable or have no last_Java_frame when in
// thread_in_native
jt->frame_anchor()->make_walkable(jt);