--- a/src/hotspot/share/prims/whitebox.cpp Thu Sep 19 09:50:11 2019 +0200
+++ b/src/hotspot/share/prims/whitebox.cpp Thu Sep 19 10:52:22 2019 +0200
@@ -820,10 +820,8 @@
WB_END
WB_ENTRY(void, WB_DeoptimizeAll(JNIEnv* env, jobject o))
- MutexLocker mu(Compile_lock);
CodeCache::mark_all_nmethods_for_deoptimization();
- VM_Deoptimize op;
- VMThread::execute(&op);
+ Deoptimization::deoptimize_all_marked();
WB_END
WB_ENTRY(jint, WB_DeoptimizeMethod(JNIEnv* env, jobject o, jobject method, jboolean is_osr))
@@ -840,8 +838,7 @@
}
result += CodeCache::mark_for_deoptimization(mh());
if (result > 0) {
- VM_Deoptimize op;
- VMThread::execute(&op);
+ Deoptimization::deoptimize_all_marked();
}
return result;
WB_END