RFR: 8355769: Optimize nmethod dependency recording [v2]
Aleksey Shipilev
shade at openjdk.org
Tue Apr 29 12:47:25 UTC 2025
On Tue, 29 Apr 2025 09:36:41 GMT, Andrew Dinn <adinn at openjdk.org> wrote:
> I checked the two callers of this method and noticed that `MethodHandles::add_dependent_nmethod` includes `assert_locked_or_safepoint(CodeCache_lock)` while `InstanceKlass::add_dependent_nmethod` has no assert. First, should both not include an assert? Second, why allow for being at a safepoint in the case of a MethodHandle rather than just assert the lock is held?
Yeah, locks are too weak in callers. We can make them stronger, as in new commit.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/24933#issuecomment-2838689318
More information about the hotspot-compiler-dev
mailing list