JDK-8264008 : Incorrect metaspace statistics after JEP 387 when UseCompressedClassPointers is off
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 16,17
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2021-03-23
  • Updated: 2021-04-09
  • Resolved: 2021-03-24
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 17
17 b15Fixed
Related Reports
Relates :  
Relates :  
Description
Reproduce:
 - run jdk/jfr/event/gc/heapsummary/TestHeapSummaryEventDefNewSerial.java with -XX:-UseCompressedClassPointers

For example, here is the incorrect metaspace statistics before the fix:
```
Event:jdk.MetaspaceSummary {
  startTime = 10:35:24.762
  gcId = 3
  when = "Before GC"
  gcThreshold = 21.0 MB
  metaspace = {
    committed = 10.3 MB
    used = 10.2 MB
    reserved = 16.0 MB
  }
  dataSpace = {
    committed = 10.3 MB
    used = 10.2 MB
    reserved = 16.0 MB
  }
  classSpace = {
    committed = 10.3 MB
    used = 10.2 MB
    reserved = 16.0 MB
  }
}
```
Comments
Changeset: 06d46d6c Author: Jie Fu <jiefu@openjdk.org> Date: 2021-03-24 09:30:54 +0000 URL: https://git.openjdk.java.net/jdk/commit/06d46d6c
24-03-2021