RFR: 8292969: Bad Thread Utilization in ForkJoinPool

Aleksey Shipilev shade at openjdk.org
Mon Sep 26 13:34:27 UTC 2022


On Mon, 26 Sep 2022 13:29:51 GMT, Doug Lea <dl at openjdk.org> wrote:

>> src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 1842:
>> 
>>> 1840:                         signalWork();           // propagate at most twice/run
>>> 1841:                     w.topLevelExec(t, q);
>>> 1842:                     return src + (prevSrc << SWIDTH);
>> 
>> Are all of these values (`src`, `prevSrc`) less or equal `0x7FFF`? Otherwise we are playing with sign bits here.
>
> Yes, see the discussions around line 391 of internal docs.

Ah, all right then.

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

PR: https://git.openjdk.org/jdk/pull/10198


More information about the core-libs-dev mailing list