RFR: 8351158: Incorrect APX EGPR register save ordering

Vladimir Kozlov kvn at openjdk.org
Tue Mar 4 18:13:59 UTC 2025


On Tue, 4 Mar 2025 12:08:57 GMT, Jatin Bhateja <jbhateja at openjdk.org> wrote:

> Currently, EGPR register save ordering[1] does not comply with the precomputed stack offsets[2]. This leads to incorrect register value reconstruction and various runtime clients using callee's RegisterMap like GC root set enumeration, de-optimization object reconstruction experience assertion failures due to unrecognizable oop pointer locations.
> 
> This issue was discovered during our internal validation of SPECjvm2008 worklets with -XX:+UseAPX runtime flag using Intel SDE tool.
> 
> Quick note on polling SafePoints :-
> SafePointNode at polling sites like method return or [outer] loop latches are different from the ones associated with Call sites as we do not spill caller saved registers before them, hence runtime handling for rootset enumeration to detect the oop pointer addresses in last activation solely relies on the RegisterMap populated by reading the RegisterSaver stack dumps. 
> 
> Kindly review and share your feedback.
> 
> Best Regards,
> Jatin
> 
> [1] https://github.com/openjdk/jdk/blob/master/src/hotspot/cpu/x86/sharedRuntime_x86_64.cpp#L268
> [2] https://github.com/openjdk/jdk/blob/master/src/hotspot/cpu/x86/sharedRuntime_x86_64.cpp#L105

Good.

-------------

Marked as reviewed by kvn (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/23895#pullrequestreview-2658528715


More information about the hotspot-compiler-dev mailing list