RFR: 8276801: gc/stress/CriticalNativeStress.java fails intermittently with Shenandoah [v2]
Aleksey Shipilev
shade at openjdk.java.net
Wed Nov 10 17:00:36 UTC 2021
On Wed, 10 Nov 2021 13:08:23 GMT, Zhengyu Gu <zgu at openjdk.org> wrote:
> > I still do not understand about `ShenandoahCodeRoots::unregister_nmethod` here. You seem to have restored the assert in the nmethod-table ([0248f1e](https://github.com/openjdk/jdk/commit/0248f1e4cd6a8311f0532c637a31bd71c9041451)), but surely the assert `ShenandoahCodeRoots::unregister_nmethod` can also be called at safepoint without `CodeCache_lock` held?
>
> It seems possible during [STW unloading](https://github.com/openjdk/jdk/blob/master/src/hotspot/share/gc/shared/parallelCleaning.cpp#L81)
>
> I will take a further look in separate CR see if we can cleanup a bit.
Why further CR, though? I think current code is guaranteed to fail that new assert during STW unloading? If so, we need to keep `assert_locked_or_safepoint` intact.
-------------
PR: https://git.openjdk.java.net/jdk/pull/6316
More information about the hotspot-gc-dev
mailing list