RFR: 8356233: NMT: tty->print_cr should not be used in VirtualMemoryTracker::add_reserved_region() [v3]
Gerard Ziemski
gziemski at openjdk.org
Wed May 28 14:34:15 UTC 2025
> To help with debugging NMT we added more info when an assert gets triggered, but we used `tty`, which is involved with locks and unfortunately it triggered:
>
>
> # Internal Error (.../open/src/hotspot/share/runtime/mutex.cpp:457), pid=1088443, tid=1088520
> # assert(false) failed: Attempting to acquire lock tty_lock/tty out of order with lock NmtVirtualMemory_lock/service-4 -- possible deadlock
>
>
> We avoid this, by printing using `UL` instead of using `tty` directly.
Gerard Ziemski has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains five additional commits since the last revision:
- Merge remote-tracking branch 'upstream/master' into JDK-8356233
- Johan's feedback
- revert debug change
- revert header change
- convert to UL
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/25308/files
- new: https://git.openjdk.org/jdk/pull/25308/files/985856ec..5b0e0f58
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=25308&range=02
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=25308&range=01-02
Stats: 62258 lines in 1064 files changed: 41067 ins; 14979 del; 6212 mod
Patch: https://git.openjdk.org/jdk/pull/25308.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/25308/head:pull/25308
PR: https://git.openjdk.org/jdk/pull/25308
More information about the hotspot-runtime-dev
mailing list