RFR: 8316417: ObjectMonitorIterator does not return the most recent monitor and is incorrect if no monitors exists [v5]
Axel Boldt-Christmas
aboldtch at openjdk.org
Tue Sep 19 09:25:33 UTC 2023
> ObjectMonitorIterator fails to return the most resent monitor added. It start with returning the `nextOM()` ObjectMonitor from the `_head` ObjectMonitor but fails to ever return the `_head` ObjectMonitor.
> The current implementation can also not handle that the `_head` is nullptr (no monitors in the system) and returns a null ObjectMonitorIterator. Which is interpreted as `monitor list not supported, too old hotspot VM`.
>
> Changed the iterator to keep return the current monitor (starts with `_head`) and decoupled `_head == nullptr` from the question if ObjectMonitorIterator is supported.
>
> Testing:
> * Passes all `serviceability/sa` tests
> * Currently running tier 1-3
> * Currently running GHA
Axel Boldt-Christmas has updated the pull request incrementally with one additional commit since the last revision:
Removed unnecessary comment
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/15782/files
- new: https://git.openjdk.org/jdk/pull/15782/files/48a6ba80..faa579a9
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=15782&range=04
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=15782&range=03-04
Stats: 1 line in 1 file changed: 0 ins; 1 del; 0 mod
Patch: https://git.openjdk.org/jdk/pull/15782.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/15782/head:pull/15782
PR: https://git.openjdk.org/jdk/pull/15782
More information about the serviceability-dev
mailing list