RFR: 8325397: sun/java2d/Disposer/TestDisposerRace.java fails in linux-aarch64

Alan Bateman alanb at openjdk.org
Tue Sep 3 09:16:31 UTC 2024


On Fri, 16 Aug 2024 09:06:48 GMT, Viktor Klang <vklang at openjdk.org> wrote:

> @DougLea @AlanBateman This seems to fix TestDisposerRace.java

That test runs with a small heap so I assume it's OOME. I can't help thinking we need to back off with a timed-Unsafe.park before retrying.

> src/java.base/share/classes/java/util/concurrent/locks/AbstractQueuedLongSynchronizer.java line 294:
> 
>> 292:                 if (first) {
>> 293:                     first = false;
>> 294:                     // Log JFR event?
> 
> @DougLea @AlanBateman The second question is whether we should declare a JFR event for this use-case or not.

Creating/recording a JFR event would require executing Java code so might be problematic.  We could potentially a VM function that could be used for many cases, except SOE.

> src/java.base/share/classes/java/util/concurrent/locks/AbstractQueuedLongSynchronizer.java line 312:
> 
>> 310:             }
>> 311:         }
>> 312:     }
> 
> @DougLea @AlanBateman So I've added such that the first exception/error is rethrown after subsequent successful reacquisition. See above.

Good.

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

PR Comment: https://git.openjdk.org/jdk/pull/20602#issuecomment-2293198541
PR Review Comment: https://git.openjdk.org/jdk/pull/20602#discussion_r1723165345
PR Review Comment: https://git.openjdk.org/jdk/pull/20602#discussion_r1731493907


More information about the core-libs-dev mailing list