[jdk11u-dev] RFR: 8213137: Remove static initialization of monitor/mutex instances
Volker Simonis
simonis at openjdk.java.net
Thu Jun 17 16:21:27 UTC 2021
On Wed, 9 Jun 2021 19:48:52 GMT, Evgeny Astigeevich <github.com+42899633+eastig at openjdk.org> wrote:
> We are backporting JDK-8210832: Remove sneaky locking in class Monitor. It has a few dependencies. JDK-8213137: Remove static initialization of monitor/mutex instances is one of them.
>
> The original patch from JDK-8213137 causes conflicts. The conflicts are because a patched file does not exist in jdk11u and git struggled to position changes. The original changes are not changed after resolution of the conflicts.
>
> Testing: Amazon Linux 2, aarch64, tier1 and tier2. Amazon Linux 2, x86_64, tier1 and tier2.
`_query_lock` is being replaced by `NMTQuery_lock` in [JDK-8213723](https://bugs.openjdk.java.net/browse/JDK-8213723). They just forgot to remove `_query_lock` from `memTracker.hpp`. The other two are static, but not initialized with a static initializer. Probably somebody has checked that initialization for them happens "late enough".
I'm fine with this downport then. Let's continue the discussion when we downport [JDK-8213723](https://bugs.openjdk.java.net/browse/JDK-8213723) :)
-------------
Marked as reviewed by simonis (Reviewer).
PR: https://git.openjdk.java.net/jdk11u-dev/pull/21
More information about the jdk-updates-dev
mailing list