RFR: 8329351: add runtime/Monitor/TestRecursiveLocking.java for recursive Java monitor stress testing

Leonid Mesnik lmesnik at openjdk.org
Tue Apr 16 23:25:00 UTC 2024


On Fri, 5 Apr 2024 19:23:52 GMT, Daniel D. Daugherty <dcubed at openjdk.org> wrote:

> The first stress test to be added is:
> 
> runtime/Monitor/TestRecursiveLocking.java
> 
> It has been tested with a couple of 12 hour runs on my MBP13:
>   - 3 build configs: release, fastdebug, slowdebug, 4 hours each, total 12 hours
>   - 18 test configs, 800 seconds each, total 4 hours
> 
> The default configuration has been tested in Mach5 Tier2 and the
> StressWrapper_TestRecursiveLocking_36M.java version has been
> tested in Mach5 Tier3.

All tests are  @requires vm.flagless

Don't we need flag-aware test which could be executed with ll VM flags?

test/hotspot/jtreg/runtime/Monitor/StressWrapper_TestRecursiveLocking_36M.java line 29:

> 27:  * @requires vm.flagless
> 28:  * @summary Tests recursive locking in -Xint in outer then inner mode.
> 29:  * @library /testlibrary /test/lib /runtime/Monitor

I don't think that '/runtime/Monitor' is required. Jtreg searches files in current directory by default.

test/hotspot/jtreg/runtime/Monitor/StressWrapper_TestRecursiveLocking_36M.java line 33:

> 31:  * @run driver jdk.test.lib.helpers.ClassFileInstaller jdk.test.whitebox.WhiteBox
> 32:  *
> 33:  * @run main/othervm/timeout=240 -Xbootclasspath/a:.

I would recommend to split this into 3 tests instead of run so jtreg might execute them in parallel and provide separate results.

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

PR Review: https://git.openjdk.org/jdk/pull/18664#pullrequestreview-1995645488
PR Review Comment: https://git.openjdk.org/jdk/pull/18664#discussion_r1561863408
PR Review Comment: https://git.openjdk.org/jdk/pull/18664#discussion_r1561862714


More information about the hotspot-runtime-dev mailing list