mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-17 01:24:33 +02:00
8233343: Deprecate -XX:+CriticalJNINatives flag which implements JavaCritical native functions
Reviewed-by: rehn, mdoerr, zgu
This commit is contained in:
parent
615b759edd
commit
56ea490f1e
18 changed files with 148 additions and 1204 deletions
|
@ -2728,26 +2728,6 @@ void JavaThread::check_special_condition_for_native_trans(JavaThread *thread) {
|
|||
}
|
||||
}
|
||||
|
||||
// This is a variant of the normal
|
||||
// check_special_condition_for_native_trans with slightly different
|
||||
// semantics for use by critical native wrappers. It does all the
|
||||
// normal checks but also performs the transition back into
|
||||
// thread_in_Java state. This is required so that critical natives
|
||||
// can potentially block and perform a GC if they are the last thread
|
||||
// exiting the GCLocker.
|
||||
void JavaThread::check_special_condition_for_native_trans_and_transition(JavaThread *thread) {
|
||||
check_special_condition_for_native_trans(thread);
|
||||
|
||||
// Finish the transition
|
||||
thread->set_thread_state(_thread_in_Java);
|
||||
|
||||
if (thread->do_critical_native_unlock()) {
|
||||
ThreadInVMfromJavaNoAsyncException tiv(thread);
|
||||
GCLocker::unlock_critical(thread);
|
||||
thread->clear_critical_native_unlock();
|
||||
}
|
||||
}
|
||||
|
||||
// We need to guarantee the Threads_lock here, since resumes are not
|
||||
// allowed during safepoint synchronization
|
||||
// Can only resume from an external suspension
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue