RFR: 8276333: jdk/jfr/event/oldobject/TestLargeRootSet.java failed "assert(!contains(edge->reference())) failed: invariant"
Erik Gahlin
egahlin at openjdk.java.net
Mon Mar 7 15:29:03 UTC 2022
On Sun, 6 Mar 2022 13:23:01 GMT, Markus Grönlund <mgronlun at openjdk.org> wrote:
> Greetings,
>
> This is a specific issue related to how the DFSClosure process roots.
>
> It traverses roots twice to avoid going sideways. To prevent premature termination during the second pass, a marker, "_ignore_root_set", is set to signal they have already been processed. It lets the recursion continue, but there is a problem with how the code is laid out. It skips the "is_marked" check, but it does not skip add_chain(). If the reference is a stack root, and the pointee is a leak sample candidate, it attempts to construct the reference chain twice. The assertion fires because a reference is only to be added once.
>
> It also includes stronger asserts to give more information for related issue tracked in [JDK-8282067](https://bugs.openjdk.java.net/browse/JDK-8282067) .
>
> Testing: jdk_jfr
>
> Thanks
> Markus
Marked as reviewed by egahlin (Reviewer).
-------------
PR: https://git.openjdk.java.net/jdk/pull/7715
More information about the hotspot-jfr-dev
mailing list