8235273: nmethodLocker not needed for COMPILED_METHOD_UNLOAD events

Remove unnecessary nmethodLocker

Reviewed-by: dholmes, sspitsyn
This commit is contained in:
Coleen Phillimore 2019-12-04 13:48:38 -05:00
parent a445b66e58
commit 5845912fdb
3 changed files with 3 additions and 15 deletions

View file

@ -1622,8 +1622,7 @@ void nmethod::post_compiled_method_unload() {
if (_jmethod_id != NULL && JvmtiExport::should_post_compiled_method_unload()) {
assert(!unload_reported(), "already unloaded");
JvmtiDeferredEvent event =
JvmtiDeferredEvent::compiled_method_unload_event(this,
_jmethod_id, insts_begin());
JvmtiDeferredEvent::compiled_method_unload_event(_jmethod_id, insts_begin());
MutexLocker ml(Service_lock, Mutex::_no_safepoint_check_flag);
JvmtiDeferredEventQueue::enqueue(event);
}