RFR: 8373118: Test java/lang/Thread/virtual/Starvation.java timed out

Viktor Klang vklang at openjdk.org
Fri Dec 12 23:04:58 UTC 2025


On Fri, 12 Dec 2025 22:56:51 GMT, Viktor Klang <vklang at openjdk.org> wrote:

>> Changes signal filtering to avoid possible starvation
>
> src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 1434:
> 
>> 1432:         final int topLevelExec(ForkJoinTask<?> task, WorkQueue q,
>> 1433:                                 int fifo, int qbase) {
>> 1434:             int stolen = 1;
> 
> @DougLea It does seem a bit weird that stolen starts as 1 even if "task == null" (i.e. this method would return 1 for an invocation where task or q is null, which doesn't sounds right?)

On the other hand, `t` is never null, and `q` is never null, so I'll just suggest a small comment below.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/28797#discussion_r2615796027


More information about the core-libs-dev mailing list