jmap -heap fails after generation array removal

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P2
    • 9
    • Affects Version/s: 9
    • Component/s: hotspot
    • gc
    • b54
    • Verified

        There is a bug in the SA code introduced by JDK-8061802.
        This patch seems to fix the issue:

        --- a/agent/src/share/classes/sun/jvm/hotspot/memory/GenCollectedHeap.java
        +++ b/agent/src/share/classes/sun/jvm/hotspot/memory/GenCollectedHeap.java
        @@ -76,9 +76,9 @@
         
             switch (i) {
             case 0:
        - return genFactory.newObject(youngGenField.getAddress());
        + return genFactory.newObject(youngGenField.getValue(addr));
             case 1:
        - return genFactory.newObject(oldGenField.getAddress());
        + return genFactory.newObject(oldGenField.getValue(addr));
             default:
               // no generation for i, and assertions disabled.
               return null;

              Assignee:
              Mikael Gerdin (Inactive)
              Reporter:
              Jesper Wilhelmsson
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: