8165018: Missing memory barrier for PPC64 in Unsafe_GetObjectVolatile

Reviewed-by: kbarrett, dholmes
This commit is contained in:
Martin Doerr 2016-09-05 20:40:08 -04:00
parent 23ceda31a0
commit 02654e7d3d

View File

@ -324,6 +324,10 @@ UNSAFE_ENTRY(jobject, Unsafe_GetObjectVolatile(JNIEnv *env, jobject unsafe, jobj
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));