RFR: 8318757: VM_ThreadDump asserts in interleaved ObjectMonitor::deflate_monitor calls [v12]

Daniel D. Daugherty dcubed at openjdk.org
Thu Nov 16 16:21:53 UTC 2023


On Thu, 16 Nov 2023 14:07:18 GMT, Stefan Karlsson <stefank at openjdk.org> wrote:

>> A safepointed monitor deflation pass can run interleaved with a paused async monitor deflation pass. The code is not written to handle that situation and asserts when it finds a DEFLATER_MARKER in the owner field. @pchilano also found other issues with having to monitor deflation passes interleaved. More info below ...
>
> Stefan Karlsson 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 21 additional commits since the last revision:
> 
>  - Merge remote-tracking branch 'upstream/master' into 8318757_interleaved_monitor_deflation
>  - More tweaks to the test
>  - Tweak test
>  - Do stuff in the synchronized block of the test
>  - Update names in test
>  - Remove the limit for deflation requests
>  - Remove reinitialization in test
>  - Update comments
>  - Tweak the flag comment a bit
>  - Add AsyncMonitorDeflationForThreadDumpLimit flag
>  - ... and 11 more: https://git.openjdk.org/jdk/compare/e75ed0ec...9e97ed90

I finally got to a wide spot in the road where I could get back to
doing code reviews. Sorry for the delay on this re-review.

Thumbs up. I found only one minor typo that could be handled
as part of some other fix.

src/hotspot/share/runtime/vmOperations.cpp line 347:

> 345:     if (monitor->is_owner_anonymous()) {
> 346:       // There's no need to collect anonymous owned monitors
> 347:       // because the callers of this code is only interested

nit typo: s/is only/are only/

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

PR Review: https://git.openjdk.org/jdk/pull/16519#pullrequestreview-1734855705
PR Review Comment: https://git.openjdk.org/jdk/pull/16519#discussion_r1395984320


More information about the hotspot-dev mailing list