RFR: 8352971: Increase maximum number of hold counts for ReentrantReadWriteLock [v2]

Viktor Klang vklang at openjdk.org
Mon Apr 7 15:05:02 UTC 2025


On Mon, 7 Apr 2025 14:03:13 GMT, Alan Bateman <alanb at openjdk.org> wrote:

>> Viktor Klang has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains two additional commits since the last revision:
>> 
>>  - Make sure that the test fails in case of an InterruptedException
>>  - Adding support for more than 65k readers and writers of ReentrantReadWriteLock
>
> test/jdk/java/util/concurrent/tck/ReentrantReadWriteLock20Test.java line 93:
> 
>> 91:             while ((next = threads.pollFirst()) != null) {
>> 92:                 while (next.isAlive()) {
>> 93:                     next.join();
> 
> You can drop the inner-while as join will wait for the thread to terminate, no-op if already terminated.

I'll leave it as-is for now 👍

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

PR Review Comment: https://git.openjdk.org/jdk/pull/24261#discussion_r2031448070


More information about the core-libs-dev mailing list