[jdk17u-dev] RFR: 8321470: ThreadLocal.nextHashCode can be static final

fitzsim duke at openjdk.org
Wed Nov 6 07:19:34 UTC 2024


On Sat, 26 Oct 2024 23:46:17 GMT, Satyen Subramaniam <ssubramaniam at openjdk.org> wrote:

> Backporting JDK-8321470: ThreadLocal.nextHashCode can be static final. Minor change makes the variable final (it is already static). Patch is clean.

_I am not a reviewer; I maintain `java-17-openjdk` in `RHEL` so I try to review `rfr`-labelled pull requests for `jdk17u-dev`, time-permitting._

This change seems safe and like a correct optimization that should improve performance.  (It would have been nice if there were some performance analysis submitted with the original pull request that could have been re-run on 17.)

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

PR Comment: https://git.openjdk.org/jdk17u-dev/pull/3007#issuecomment-2458875082


More information about the jdk-updates-dev mailing list