On Wed, 29 May 2024 11:33:40 GMT, Doug Lea <d...@openjdk.org> wrote:

>> This set of changes address causes of poor utilization with small numbers of 
>> cores due to overly aggressive contention avoidance. A number of further 
>> adjustments were needed to still avoid most contention effects in 
>> deployments with large numbers of cores
>
> Doug Lea 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 41 additional commits since 
> the last revision:
> 
>  - Merge branch 'openjdk:master' into JDK-8322732
>  - Add test for utilization with interdependent tasks
>  - Un-misplace onSpinWait call
>  - Adjust control flow
>  - Reduce memory stalls
>  - Merge branch 'openjdk:master' into JDK-8322732
>  - More performance tradoffs
>  - Address review comments
>  - Merge branch 'openjdk:master' into JDK-8322732
>  - Repack some fields; adjust control flow
>  - ... and 31 more: https://git.openjdk.org/jdk/compare/3d109313...cf5fe55c

src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java line 2061:

> 2059:                 w.stackPred = (int)pc;           // set ctl stack link
> 2060:                 qc = (active & LMASK) | ((pc - RC_UNIT) & UMASK);
> 2061:                 if (pc == (pc = compareAndExchangeCtl(pc, qc)))

If I'm reading this right you might want to add a comment :)

Suggestion:

                if (pc == (pc = compareAndExchangeCtl(pc, qc))) // consistent

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

PR Review Comment: https://git.openjdk.org/jdk/pull/19131#discussion_r1618974704

Reply via email to