RFR: 8290892: C2: Intrinsify Reference.reachabilityFence [v19]
Vladimir Ivanov
vlivanov at openjdk.org
Tue Nov 4 21:08:17 UTC 2025
On Tue, 4 Nov 2025 08:42:24 GMT, Emanuel Peter <epeter at openjdk.org> wrote:
>> Done.
>
> @iwanowww Thanks for the comments!
>
> I'm still not 100% happy with it. It really feels like we are introducing some tech-debt here. What should the next person do who also needs to attach something else to the SafePoint? It is also easy to miss places where we have to special case the extra edges. I don't have a solution here, I'm just not extremely satisfied. Is there a better long-term solution?
I don't think we can improve things much without paying existing tech debt related to managing non-debug edges.
The two cases I spotted relates to scalarization and is not aware about non-debug inputs a safepoint may have. Both implementations assume there's only debug info attached and tweak it by appending new edges and extending debug info range to cover them. Without a proper API to manage safepoint-attached debug information, it'll always be fragile.
JDK-8370133 "C2: Manage non-debug safepoint edges in structural manner" should address the root cause and introduce a proper way to work with safepoint-attached debug and non-debug information.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/25315#discussion_r2492046349
More information about the hotspot-compiler-dev
mailing list