If a memory access (either load or store) dependent on a referent of a ReachabilityFence node floats past the corresponding ReachabilityFence node, it may break a ReachabilityFence guarantee if it then floats past a safepoint (those aren't classified as interfering by JDK-8290892).
If ReachabilityFence is represented as a memory barrier, it would guarantee such scheduling is impossible, but MemBar IR representation is prohibitively expensive (from performance POV).
One way to address it is to make interfering safepoint enumeration algorithm in JDK-8290892 more conservative and consider any safepoints reachable from referent control as interfering.
If ReachabilityFence is represented as a memory barrier, it would guarantee such scheduling is impossible, but MemBar IR representation is prohibitively expensive (from performance POV).
One way to address it is to make interfering safepoint enumeration algorithm in JDK-8290892 more conservative and consider any safepoints reachable from referent control as interfering.
- relates to
-
JDK-8290892 C2: Intrinsify Reference.reachabilityFence
-
- In Progress
-