JDK-8265124 : Suspend with handshakes
  • Type: CSR
  • Component: hotspot
  • Sub-Component: runtime
  • Priority: P4
  • Status: Closed
  • Resolution: Approved
  • Fix Versions: 17
  • Submitted: 2021-04-13
  • Updated: 2021-04-15
  • Resolved: 2021-04-15
Related Reports
CSR :  
Description
Summary
-------

Obsolete the `-XX:SuspendRetryCount` and `-XX:SuspendRetryDelay` flags.

Problem
-------

The mechanism for suspending and resuming is being changed.
These flags are not used by the new mechanism.

Solution
--------

Immediately obsolete the flags in the change-set which changes the suspend/resume mechanism.

Specification
-------------

The flags will now generate this warning:

    Java HotSpot(TM) 64-Bit Server VM warning: Ignoring option SuspendRetryDelay; support was removed in 17.0

Full PR:
https://github.com/openjdk/jdk/pull/3191

Commit: https://github.com/openjdk/jdk/pull/3191/commits/5034e8a54467b942186fc7da61ec04a8008b4aa5

Changes for the flags:

    diff --git a/src/hotspot/share/runtime/arguments.cpp b/src/hotspot/share/runtime/arguments.cpp
    index b17cd9e7ded..fdce017ba73 100644
    --- a/src/hotspot/share/runtime/arguments.cpp
    +++ b/src/hotspot/share/runtime/arguments.cpp
    @@ -523,0 +524,2 @@ static SpecialFlag const special_jvm_flags[] = {
    +  { "SuspendRetryCount",            JDK_Version::undefined(), JDK_Version::jdk(17), JDK_Version::jdk(18) },
    +  { "SuspendRetryDelay",            JDK_Version::undefined(), JDK_Version::jdk(17), JDK_Version::jdk(18) },

    diff --git a/src/hotspot/share/runtime/globals.hpp b/src/hotspot/share/runtime/globals.hpp
    index 1c22dc7718c..382dbdaa960 100644
    --- a/src/hotspot/share/runtime/globals.hpp
    +++ b/src/hotspot/share/runtime/globals.hpp
    @@ -429,10 +428,0 @@ const intx ObjectAlignmentInBytes = 8;
    -  /* 50 retries * (5 * current_retry_count) millis = ~6.375 seconds */      \
    -  /* typically, at most a few retries are needed                    */      \
    -  product(intx, SuspendRetryCount, 50,                                      \
    -          "Maximum retry count for an external suspend request")            \
    -          range(0, max_intx)                                                \
    -                                                                            \
    -  product(intx, SuspendRetryDelay, 5,                                       \
    -          "Milliseconds to delay per retry (* current_retry_count)")        \
    -          range(0, max_intx)                                                \
    -                                                                            \



Comments
Thank you guys!
15-04-2021

Moving to Approved.
15-04-2021

Moving to Provisional.
14-04-2021

The title of the CSR request should match the title of the issue with which it is associated so I changed it.
14-04-2021

As the suspend mechanism is changing and these flags have become meaningless, their direct obsoletion is appropriate. It is very unlikely that anyone actually uses these flags (which arguably should have been diagnostic), so I have no concerns with regards to compatibility. [~rehn] please move this to finalized once the deprecation version has been corrected. Thanks.
14-04-2021

Yes it should be undefined() as they were never deprecated.
14-04-2021

The first column is for: JDK_Version deprecated_in; // When the deprecation warning started (or "undefined"). and we definitely didn't deprecate these two flags in JDK16. I believe we are deprecating and obsoleting these two flags in the same release so that first column should have 'jdk(17)' instead of 'jdk(16)'. Or perhaps 'undefined' since we didn't deprecate before obsoleting. [~dholmes] would know the answer here.
13-04-2021