src/hotspot/share/classfile/classLoader.inline.hpp
changeset 59247 56bf71d64d51
parent 58447 319173c62caa
child 59290 97d13893ec3c
equal deleted inserted replaced
59246:fcad92f425c5 59247:56bf71d64d51
    27 
    27 
    28 #include "classfile/classLoader.hpp"
    28 #include "classfile/classLoader.hpp"
    29 #include "runtime/orderAccess.hpp"
    29 #include "runtime/orderAccess.hpp"
    30 
    30 
    31 // Next entry in class path
    31 // Next entry in class path
    32 inline ClassPathEntry* ClassPathEntry::next() const { return OrderAccess::load_acquire(&_next); }
    32 inline ClassPathEntry* ClassPathEntry::next() const { return Atomic::load_acquire(&_next); }
    33 
    33 
    34 inline void ClassPathEntry::set_next(ClassPathEntry* next) {
    34 inline void ClassPathEntry::set_next(ClassPathEntry* next) {
    35   // may have unlocked readers, so ensure visibility.
    35   // may have unlocked readers, so ensure visibility.
    36   OrderAccess::release_store(&_next, next);
    36   Atomic::release_store(&_next, next);
    37 }
    37 }
    38 
    38 
    39 inline ClassPathEntry* ClassLoader::classpath_entry(int n) {
    39 inline ClassPathEntry* ClassLoader::classpath_entry(int n) {
    40   assert(n >= 0, "sanity");
    40   assert(n >= 0, "sanity");
    41   if (n == 0) {
    41   if (n == 0) {