src/hotspot/share/gc/z/zResurrection.inline.hpp
changeset 59253 1647ed87bf1e
parent 50525 767cdb97f103
--- a/src/hotspot/share/gc/z/zResurrection.inline.hpp	Mon Nov 25 12:33:15 2019 +0100
+++ b/src/hotspot/share/gc/z/zResurrection.inline.hpp	Mon Nov 25 14:56:15 2019 +0100
@@ -25,14 +25,10 @@
 #define SHARE_GC_Z_ZRESURRECTION_INLINE_HPP
 
 #include "gc/z/zResurrection.hpp"
-#include "runtime/orderAccess.hpp"
+#include "runtime/atomic.hpp"
 
 inline bool ZResurrection::is_blocked() {
-  // We use a loadload barrier to make sure we are not
-  // seeing oops from a time when resurrection was blocked.
-  const bool blocked = _blocked;
-  OrderAccess::loadload();
-  return blocked;
+  return Atomic::load(&_blocked);
 }
 
 #endif // SHARE_GC_Z_ZRESURRECTION_INLINE_HPP