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

x86_32: assert(all_ro_bytes == ro_all) failed: everything should have been counted

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P3 P3
    • None
    • 16
    • hotspot
    • None

      Testing the JDK-8254125 fix candidate. runtime/cds/SharedArchiveFile.java used to fail with the exception from JDK-8254125, but after the candidate fix it fails with:

      ```
      $ CONF=linux-x86-server-fastdebug make images run-test TEST=runtime/cds/SharedArchiveFile.java

      # A fatal error has been detected by the Java Runtime Environment:
      #
      # Internal Error (/home/shade/trunks/jdk/src/hotspot/share/memory/dumpAllocStats.cpp:113), pid=439540, tid=439548
      # assert(all_ro_bytes == ro_all) failed: everything should have been counted
      ```

      Adding `-Xlog:cds=debug` to the test and `msg.flush()` to `DumpAllocStats::print_stats` reveals a difference of 8 bytes between "ro used" and ro calculated:

      ```
      [0.742s][debug ][cds] ro space: 6257896 [ 69.0% of total] out of 6258688 bytes [100.0% used] at 0x8026a000
      ...
      [0.742s][debug ][cds] --------------------+---------------------------+---------------------------+--------------------------
      [0.742s][debug ][cds] Total : 120738 6257888 100.0 | 24192 2528152 100.0 | 144930 8786040 100.0
      ```

      See: 6257896 - 6257888 = 8

      Is this the same issue as JDK-8254125, or something else?

            iklam Ioi Lam
            shade Aleksey Shipilev
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: