Skip to content

Commit

Permalink
JDK-8320335: Deprecate RegisterFinalizersAtInit option and code
Browse files Browse the repository at this point in the history
Deprecate the -XX:[+-]RegisterFinalizersAtInit option in JDK22.
Goal is complete removal by JDK24.
  • Loading branch information
DanHeidinga committed Nov 20, 2023
1 parent c788160 commit 180df75
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/hotspot/share/runtime/arguments.cpp
Expand Up @@ -509,6 +509,7 @@ static SpecialFlag const special_jvm_flags[] = {
{ "DynamicDumpSharedSpaces", JDK_Version::jdk(18), JDK_Version::jdk(19), JDK_Version::undefined() },
{ "RequireSharedSpaces", JDK_Version::jdk(18), JDK_Version::jdk(19), JDK_Version::undefined() },
{ "UseSharedSpaces", JDK_Version::jdk(18), JDK_Version::jdk(19), JDK_Version::undefined() },
{ "RegisterFinalizersAtInit", JDK_Version::jdk(22), JDK_Version::jdk(23), JDK_Version::jdk(24) },

// --- Deprecated alias flags (see also aliased_jvm_flags) - sorted by obsolete_in then expired_in:
{ "DefaultMaxRAMFraction", JDK_Version::jdk(8), JDK_Version::undefined(), JDK_Version::undefined() },
Expand Down
4 changes: 2 additions & 2 deletions src/hotspot/share/runtime/globals.hpp
Expand Up @@ -667,8 +667,8 @@ const int ObjectAlignmentInBytes = 8;
"Print JVM warnings to output stream") \
\
product(bool, RegisterFinalizersAtInit, true, \
"Register finalizable objects at end of Object.<init> or " \
"after allocation") \
"(Deprecated) Register finalizable objects at end of " \
"Object.<init> or after allocation") \
\
develop(bool, RegisterReferences, true, \
"Tell whether the VM should register soft/weak/final/phantom " \
Expand Down

0 comments on commit 180df75

Please sign in to comment.