RFR: 8273639: tests fail with "assert(_handle_mark_nesting > 1) failed: memory leak: allocating handle outside HandleMark"
David Holmes
dholmes at openjdk.java.net
Tue Sep 14 02:21:06 UTC 2021
On Mon, 13 Sep 2021 11:57:05 GMT, Per Liden <pliden at openjdk.org> wrote:
> This is a fix for an unintended side-effect of JDK-8273482. The problem is that we need to have a HandleMark on the stack before calling ThreadStackTrace::dump_stack_at_safepoint(). Before JDK-8273482, calls to ThreadStackTrace::dump_stack_at_safepoint() were always done from the VMThread, which always has a HandleMark on the stack before evaluating a VM operation. After JDK-8273482, calls to this function can be made from WorkerThreads, which doesn't always have a HandleMark on its stack. The fix is simple, make sure we have a HandleMark on the stack before calling ThreadStackTrace::dump_stack_at_safepoint().
Looks good.
Thanks,
David
-------------
Marked as reviewed by dholmes (Reviewer).
PR: https://git.openjdk.java.net/jdk/pull/5492
More information about the hotspot-runtime-dev
mailing list