RFR: 8351565: Implement JEP 502: Stable Values (Preview) [v33]

Per Minborg pminborg at openjdk.org
Thu Apr 3 10:56:27 UTC 2025


On Wed, 2 Apr 2025 18:49:31 GMT, Viktor Klang <vklang at openjdk.org> wrote:

>> Per Minborg has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Add info that Map#values and Map#entrySet are stable
>
> test/jdk/java/lang/StableValue/StableValueTest.java line 262:
> 
>> 260:         threads.forEach(StableValueTest::join);
>> 261:         // There can only be one winner
>> 262:         assertEquals(1, winner.cardinality());
> 
> AFAIK BitSet is not thread safe, so you have multiple threads writing to it—which may or may not provide the right guarantees to lean on for this test. Might be better to lean on CHM.

Nice catch. Thanks!

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

PR Review Comment: https://git.openjdk.org/jdk/pull/23972#discussion_r2026740369


More information about the core-libs-dev mailing list