RFR: 8219687: G1 asserts nmethod should not be unloaded during parallel code cache unloading

Thomas Schatzl thomas.schatzl at oracle.com
Fri Jun 7 09:52:57 UTC 2019

Hi Erik,

On Mon, 2019-06-03 at 17:39 +0200, Erik Österlund wrote:
> Hi,
> There is an assert that G1 occasionally hits during parallel code
> cache unloading.
> When oops_do() is called to compute is_unloading(), the nmethod
> should not be unloaded says the assert.
> However... imagine the following scenario:
> [...]
> So there is absolutely no harm with calling oops_do on nmethods that 
> racingly become unloaded here, and that assertion should just be
> silenced.
> Webrev:
> http://cr.openjdk.java.net/~eosterlund/8219687/webrev.00/
> Bug:
> https://bugs.openjdk.java.net/browse/JDK-8219687

  looks good.

Could you fix the comment in the call to nmethod::oops_do() in
shenandoahCodeRoots.cpp too?

No need for re-review.


More information about the hotspot-gc-dev mailing list