RFR: 8318757: VM_ThreadDump asserts in interleaved ObjectMonitor::deflate_monitor calls [v2]
Stefan Karlsson
stefank at openjdk.org
Mon Nov 6 20:21:33 UTC 2023
On Mon, 6 Nov 2023 19:38:06 GMT, Patricio Chilano Mateo <pchilanomate at openjdk.org> wrote:
> I see this monitor traversal in VM_ThreadDump is just to get the monitors locked through JNI. But we now have the _jni_monitor_count counter so all this traversal could be made conditional, which most of the times will mean we won't have to do it.
Good point. If we need to optimize this in the future, this could be a good thing to implement. Right now I'm not sure it is worth it, given that the iteration is fairly quick, unless there is a brutal amount of monitors, but then it might be better to look into the deflation mechanisms instead.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/16519#issuecomment-1796366135
More information about the hotspot-dev
mailing list