8212053: A few more missing object equals barriers

Reviewed-by: shade, zgu
This commit is contained in:
Roman Kennke 2018-10-12 16:25:24 +02:00
parent 96b43418b5
commit f958e6642e
2 changed files with 2 additions and 2 deletions

View file

@ -66,7 +66,7 @@ namespace CompressedOops {
assert(OopEncodingHeapMax > pd, "change encoding max if new encoding"); assert(OopEncodingHeapMax > pd, "change encoding max if new encoding");
uint64_t result = pd >> shift; uint64_t result = pd >> shift;
assert((result & CONST64(0xffffffff00000000)) == 0, "narrow oop overflow"); assert((result & CONST64(0xffffffff00000000)) == 0, "narrow oop overflow");
assert(decode(result) == v, "reversibility"); assert(oopDesc::equals_raw(decode(result), v), "reversibility");
return (narrowOop)result; return (narrowOop)result;
} }

View file

@ -134,7 +134,7 @@ GrowableArray<MonitorInfo*>* javaVFrame::locked_monitors() {
// //
// Skip the monitor that the thread is blocked to enter or waiting on // Skip the monitor that the thread is blocked to enter or waiting on
// //
if (!found_first_monitor && (obj == pending_obj || obj == waiting_obj)) { if (!found_first_monitor && (oopDesc::equals(obj, pending_obj) || oopDesc::equals(obj, waiting_obj))) {
continue; continue;
} }
found_first_monitor = true; found_first_monitor = true;