diff --git a/src/hotspot/share/code/nmethod.cpp b/src/hotspot/share/code/nmethod.cpp index e519dc3..65ce9a5 100644 --- a/src/hotspot/share/code/nmethod.cpp +++ b/src/hotspot/share/code/nmethod.cpp @@ -1108,8 +1108,9 @@ void nmethod::make_unloaded() { // The release is only needed for compile-time ordering, as accesses // into the nmethod after the store is not safe, due to the sweeper - // being allowed to free it then, in the case of concurrent nmethod - // unloading. Therefore, there is no need for acquire on the loader side. + // being allowed to free it when the store is observed, during + // concurrent nmethod unloading. Therefore, there is no need for + // acquire on the loader side. OrderAccess::release_store(&_state, (signed char)unloaded); } @@ -1846,7 +1847,7 @@ void nmethod::check_all_dependencies(DepChange& changes) { // Iterate over live nmethods and check dependencies of all nmethods that are not // marked for deoptimization. A particular dependency is only checked once. - NMethodIterator iter(true /* only_alive */, true /* only_not_unloading */); + NMethodIterator iter(NMethodIterator::only_alive_and_not_unloading); while(iter.next()) { nmethod* nm = iter.method(); // Only notify for live nmethods