On Mon, 23 Jun 2025 10:39:59 GMT, Anton Artemov <d...@openjdk.org> wrote:
>> test/hotspot/jtreg/runtime/Monitor/StressWrapper_TestRecursiveLocking_36M.java >> line 36: >> >>> 34: * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI >>> 35: * -Xint >>> 36: * -XX:LockingMode=0 >> >> I was wondering why these LockingMode=0 test cases were not setting >> `VerifyHeavyMonitors` instead, but I'm assuming the intent now is that we >> will only test that mode when it is set externally by the user (or in our >> case a particular test task definition)? >> >> I also realized we can only test heavy monitors in tests where we explicitly >> control the monitor creation places and hence can call the WB method to >> force inflation. That obviously reduces the test coverage for that mode >> quite significantly - but perhaps that will be handled if in the future we >> implicitly reenable forced inflation and do away with the WB usage. > > My understanding is that VerifyHeavyMonitors requires LockingMode = 0, see > line 1852 of arguments.cpp. So one has to set both at the same time, not one > instead of another. Now locking mode is hardcoded to lightweight, and there > is no way to use the incompatible `VerifyHeavyMonitors` option. My understanding was that `VerifyHeavyMonitors` was to be used as a replacement for `LockingMode=0` aka `UseHeavyMonitors`. But as Coleen has requested all `VerifyHeavyMonitors` testing be removed this is now a moot point. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/25847#discussion_r2162866307