src/hotspot/share/code/dependencyContext.cpp
changeset 59247 56bf71d64d51
parent 52819 022420a4cc63
child 59248 e92153ed8bdc
equal deleted inserted replaced
59246:fcad92f425c5 59247:56bf71d64d51
   279 // an is_unloading nmethod. Any nmethodBucket entries observed from the original head
   279 // an is_unloading nmethod. Any nmethodBucket entries observed from the original head
   280 // that is_unloading() will be unlinked and placed on the purge list.
   280 // that is_unloading() will be unlinked and placed on the purge list.
   281 nmethodBucket* DependencyContext::dependencies_not_unloading() {
   281 nmethodBucket* DependencyContext::dependencies_not_unloading() {
   282   for (;;) {
   282   for (;;) {
   283     // Need acquire becase the read value could come from a concurrent insert.
   283     // Need acquire becase the read value could come from a concurrent insert.
   284     nmethodBucket* head = OrderAccess::load_acquire(_dependency_context_addr);
   284     nmethodBucket* head = Atomic::load_acquire(_dependency_context_addr);
   285     if (head == NULL || !head->get_nmethod()->is_unloading()) {
   285     if (head == NULL || !head->get_nmethod()->is_unloading()) {
   286       return head;
   286       return head;
   287     }
   287     }
   288     nmethodBucket* head_next = head->next();
   288     nmethodBucket* head_next = head->next();
   289     OrderAccess::loadload();
   289     OrderAccess::loadload();