RFR: 8256425: Obsolete Biased Locking in JDK 18
David Holmes
david.holmes at oracle.com
Fri Jun 18 03:17:15 UTC 2021
On 18/06/2021 11:56 am, Vladimir Kozlov wrote:
>
> Very nice clean up. Thank you. I have small nitpick and question about BiasedLocking flags deprecation. Obsolete flags [table](https://github.com/openjdk/jdk/blob/master/src/hotspot/share/runtime/arguments.cpp#L537) says: ```{ "UseBiasedLocking", JDK_Version::jdk(15), JDK_Version::jdk(18), JDK_Version::jdk(19) },```
>
> It means in JDK 18 JVM have to accept flags on command line but issue warning.
Correct.
> May be I mistaking, but it means you can not remove flags declaration.
You can remove the flag (and must). Obsolete flags are handled purely by
lookup in the obsolete flag table. Once a flag is obsoleted there should
only be one occurrence left of it in the source code - in that table. :)
Cheers,
David
-----
> You can remove corresponding code.
>
> src/hotspot/cpu/ppc/vm_version_ppc.cpp line 382:
>
>> 380: if (UseRTMLocking) {
>> 381: // If CPU or OS do not support TM:
>> 382: // Can't continue because UseRTMLocking affects UseBiasedLocking flag
>
> Can you fix in previous line `TM` -> `RTM`
>
> -------------
>
> PR: https://git.openjdk.java.net/jdk/pull/4522
>
More information about the hotspot-dev
mailing list