[jdk8u-dev] RFR: 8217612: (CL)HSDB cannot show some JVM flags

ktakakuri duke at openjdk.org
Thu Jan 25 11:47:44 UTC 2024


Hi all, this is a backport of JDK-8217612: (CL)HSDB cannot show some JVM flags.
The bug reported is reproducible in JDK8, so this patch should be applied.
This patch requires the follow-up patch JDK-8217850 and the correspoding pull request has been submitted.
The original patch does not apply cleanly, and the following modifications are needed:

hotspot/agent/src/share/classes/sun/jvm/hotspot/runtime/VM.java

* Long.toUnsignedString method was introduced in JDK8, and the build fails with JDK7 as the boot-jdk when using this method. Consequently, an alternative private method to Long.toUnsignedString(long i, 10) is required in VM.java.
* The size_t type was introduced in JDK9, so the related fix is skipped.
* To return a String value in the getValue method, the original fix uses a static method, whereas this fix creates a new instance each time. The use of a static method was introduced to JDK-9 in the enhancement JDK-8145061. This enhancement has not been backported, so the same format as the other part of the getValue() method should be used.
* Replace var with String.

-------------

Commit messages:
 - d6a75a0f86d4c84132a3794c432b34068163fa60

Changes: https://git.openjdk.org/jdk8u-dev/pull/431/files
 Webrev: https://webrevs.openjdk.org/?repo=jdk8u-dev&pr=431&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8217612
  Stats: 220 lines in 3 files changed: 215 ins; 0 del; 5 mod
  Patch: https://git.openjdk.org/jdk8u-dev/pull/431.diff
  Fetch: git fetch https://git.openjdk.org/jdk8u-dev.git pull/431/head:pull/431

PR: https://git.openjdk.org/jdk8u-dev/pull/431


More information about the jdk8u-dev mailing list