RFR: 8316417: ObjectMonitorIterator does not return the most recent monitor and is incorrect if no monitors exists [v6]

Chris Plummer cjplummer at openjdk.org
Mon Sep 25 21:35:18 UTC 2023


On Mon, 25 Sep 2023 14:33:15 GMT, Chris Plummer <cjplummer at openjdk.org> wrote:

> This code is called when you choose the hsdb "Tools -> Monitor Cache Dump" menu item. Have you tried doing that? I tried running it against a clhsdb process, and currently it doesn't seem to show any monitors. Does it show one after your fix?

I just tried with your fix and now it shows one monitor:


Monitor Cache Dump (not including JVMTI raw monitors):

ObjectMonitor at 0x00007f26040010b0
  _header: 0x1
  _object: 0x00000000a0001750, a java/lang/ref/NativeReferenceQueue$Lock
  _owner: null
  _contentions: 0
  _waiters: 1
  _recursions: 0

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

PR Review Comment: https://git.openjdk.org/jdk/pull/15782#discussion_r1336408860


More information about the serviceability-dev mailing list