@@ -776,15 +776,11 @@ void JVMCINMethodData::add_failed_speculation(nmethod* nm, jlong speculation) {
776776 FailedSpeculation::add_failed_speculation (nm, _failed_speculations, data, length);
777777}
778778
779- oop JVMCINMethodData::get_nmethod_mirror (nmethod* nm, bool phantom_ref ) {
779+ oop JVMCINMethodData::get_nmethod_mirror (nmethod* nm) {
780780 if (_nmethod_mirror_index == -1 ) {
781781 return nullptr ;
782782 }
783- if (phantom_ref) {
784- return nm->oop_at_phantom (_nmethod_mirror_index);
785- } else {
786- return nm->oop_at (_nmethod_mirror_index);
787- }
783+ return nm->oop_at (_nmethod_mirror_index);
788784}
789785
790786void JVMCINMethodData::set_nmethod_mirror (nmethod* nm, oop new_mirror) {
@@ -802,7 +798,7 @@ void JVMCINMethodData::set_nmethod_mirror(nmethod* nm, oop new_mirror) {
802798}
803799
804800void JVMCINMethodData::invalidate_nmethod_mirror (nmethod* nm) {
805- oop nmethod_mirror = get_nmethod_mirror (nm, /* phantom_ref */ false );
801+ oop nmethod_mirror = get_nmethod_mirror (nm);
806802 if (nmethod_mirror == nullptr ) {
807803 return ;
808804 }
@@ -2178,7 +2174,7 @@ JVMCI::CodeInstallResult JVMCIRuntime::register_method(JVMCIEnv* JVMCIENV,
21782174 JVMCINMethodData* data = nm->jvmci_nmethod_data ();
21792175 assert (data != nullptr , " must be" );
21802176 if (install_default) {
2181- assert (!nmethod_mirror.is_hotspot () || data->get_nmethod_mirror (nm, /* phantom_ref */ false ) == nullptr , " must be" );
2177+ assert (!nmethod_mirror.is_hotspot () || data->get_nmethod_mirror (nm) == nullptr , " must be" );
21822178 if (entry_bci == InvocationEntryBci) {
21832179 // If there is an old version we're done with it
21842180 nmethod* old = method->code ();
@@ -2221,7 +2217,7 @@ JVMCI::CodeInstallResult JVMCIRuntime::register_method(JVMCIEnv* JVMCIENV,
22212217 }
22222218 }
22232219 } else {
2224- assert (!nmethod_mirror.is_hotspot () || data->get_nmethod_mirror (nm, /* phantom_ref */ false ) == HotSpotJVMCI::resolve (nmethod_mirror), " must be" );
2220+ assert (!nmethod_mirror.is_hotspot () || data->get_nmethod_mirror (nm) == HotSpotJVMCI::resolve (nmethod_mirror), " must be" );
22252221 MutexLocker ml (NMethodState_lock, Mutex::_no_safepoint_check_flag);
22262222 if (!nm->make_in_use ()) {
22272223 result = JVMCI::nmethod_reclaimed;
0 commit comments