Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8191422

Deprecate PrintSafepointStatistics, PrintSafepointStatisticsTimeout and PrintSafepointStatisticsCount options

XMLWordPrintable

    • Icon: CSR CSR
    • Resolution: Approved
    • Icon: P3 P3
    • 11
    • hotspot
    • None
    • behavioral
    • minimal
    • Some customers may have used this option in the past and are familiar with the output and will notice that it's different (but the same info will be there).
    • add/remove/modify command line option
    • Implementation

      Summary

      Deprecate PrintSafepointStatistics, PrintSafepointStatisticsTimeout and PrintSafepointStatisticsCount in favor of using Unified Logging -Xlog:safepoint+stats

      Problem

      These options log information to the terminal and contribute to the huge number of various Hotspot options. The logging format of this PrintSafepointStatistics is hard to understand because it prints a very wide table with a header every 30 lines at an interval specified by PrintSafepointStatisticsCount. This format makes it hard to find the information that you're looking for (ie #threads still running etc).

      Solution

      Code under these options will be converted to Unified Logging and pass output stream to print to.

      Specification

      Currently:

      product(bool, PrintSafepointStatistics, false,
      "Print statistics about safepoint synchronization")

      product(intx, PrintSafepointStatisticsCount, 300,
      "Total number of safepoint statistics collected "
      "before printing them out")
      range(1, max_intx)

      product(intx, PrintSafepointStatisticsTimeout, -1,
      "Print safepoint statistics only when safepoint takes "
      "more than PrintSafepointSatisticsTimeout in millis")
      LP64_ONLY(range(-1, max_intx/MICROUNITS))
      NOT_LP64(range(-1, max_intx))

      Proposed:

      Short term: Print a deprecation message for each of these 3 options and convert to UL in JDK12.

      Long term:

      -XX:+PrintSafepointStatistics becomes -Xlog:safepoint+stats=debug

      PrintSafepointStatisticsTimeout is removed. This option controlled when the PrintSafepointStatistics would print the line, ie print for every safepoint after the given timeout.

      -XX:+PrintSafepointStatisticsCount is removed. Unified logging prints out for every safepoint. Collecting the info is as time consuming as printing them out with UL.

            coleenp Coleen Phillimore
            coleenp Coleen Phillimore
            David Holmes
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: