RFR: 8336489: Track scoped accesses in JVMCI compiled code [v2]
Carlo Refice
duke at openjdk.org
Tue Jul 23 12:45:03 UTC 2024
> This PR adds JVMCI support to scoped access tracking introduced in #20158.
>
> In this PR:
> * The `Method::is_scoped` flag is now exposed in JVMCI as `HotSpotResolvedJavaMethod.isScoped()`, and serialized to / deserialized from the JVMCI compiled code stream as a boolean flag.
> * To determine whether a compiled method has a scoped access, we simply check `HotSpotResolvedJavaMethod.isScoped()` returns `true` for the root method or any of the methods that were inlined in the compilation.
> * The above check is implemented as the method `HotSpotCompiledNMethod.hasScopedAccess()`, instead of as an explicit flag set in a the constructor of `HotSpotCompiledNMethod`. This keeps the change isolated to JVMCI, without requiring coordinated changes to the Graal compiler. No other changes in the compiler are necessary to benefit from the optimization.
Carlo Refice has updated the pull request incrementally with one additional commit since the last revision:
Clarify HotSpotResolvedJavaMethod#isScoped javadoc
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/20256/files
- new: https://git.openjdk.org/jdk/pull/20256/files/5f961087..1f60dae3
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=20256&range=01
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=20256&range=00-01
Stats: 2 lines in 1 file changed: 1 ins; 0 del; 1 mod
Patch: https://git.openjdk.org/jdk/pull/20256.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/20256/head:pull/20256
PR: https://git.openjdk.org/jdk/pull/20256
More information about the hotspot-compiler-dev
mailing list