[lworld] RFR: 8368875: [lworld] UseParallelGC fails null narrow klass assertion failure

Coleen Phillimore coleenp at openjdk.org
Fri Oct 3 19:36:19 UTC 2025


On Fri, 3 Oct 2025 19:24:46 GMT, Frederic Parain <fparain at openjdk.org> wrote:

>> The bug was that in parallelGC it is unsafe to retrieve the K-Klass to find these properties to re-initialize the moved object.  The moved object has written over the markWord because it's not preserved.  Adding the code that we must preserve the mark word because these bits matter fixes the bug because then the moved object will have these bits.
>
> Replying to myself: The answer seems to be in the comment in oop.inline.hpp:98, but it would be nice to know the exact reason.

I agree, it would be good to have a GC expert explain this @albertnetymk ?  Paul can follow up with him next week.  I think it's inherent in the parallelCompaction algorithm that the klass is lost (and then found again?) at this point.

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

PR Review Comment: https://git.openjdk.org/valhalla/pull/1655#discussion_r2403141248


More information about the valhalla-dev mailing list