8165018: Missing memory barrier for PPC64 in Unsafe_GetObjectVolatile
authormdoerr
Mon, 05 Sep 2016 20:40:08 -0400
changeset 40918 4b0a28b0ed28
parent 40917 22ce5e78e152
child 40919 798ce6307a9b
8165018: Missing memory barrier for PPC64 in Unsafe_GetObjectVolatile Reviewed-by: kbarrett, dholmes
hotspot/src/share/vm/prims/unsafe.cpp
--- a/hotspot/src/share/vm/prims/unsafe.cpp	Wed Aug 31 09:38:46 2016 +0200
+++ b/hotspot/src/share/vm/prims/unsafe.cpp	Mon Sep 05 20:40:08 2016 -0400
@@ -324,6 +324,10 @@
 
   volatile oop v;
 
+  if (support_IRIW_for_not_multiple_copy_atomic_cpu) {
+    OrderAccess::fence();
+  }
+
   if (UseCompressedOops) {
     volatile narrowOop n = *(volatile narrowOop*) addr;
     (void)const_cast<oop&>(v = oopDesc::decode_heap_oop(n));