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

FileMapInfo::map_heap_regions_impl fails to relocate archive regions to runtime heap top in some cases

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: P4 P4
    • tbd
    • 12
    • hotspot

      Stefan Johansson reported that the archive heap regions are not relocated to the runtime heap top in following case:

      bin/java -Xlog:cds,region*=trace -Xmx64m -XX:G1HeapRegionSize=2m -version
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fc000000, 0x00000000fc000000, 0x00000000fc200000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fc200000, 0x00000000fc200000, 0x00000000fc400000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fc400000, 0x00000000fc400000, 0x00000000fc600000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fc600000, 0x00000000fc600000, 0x00000000fc800000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fc800000, 0x00000000fc800000, 0x00000000fca00000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fca00000, 0x00000000fca00000, 0x00000000fcc00000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fcc00000, 0x00000000fcc00000, 0x00000000fce00000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fce00000, 0x00000000fce00000, 0x00000000fd000000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fd000000, 0x00000000fd000000, 0x00000000fd200000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fd200000, 0x00000000fd200000, 0x00000000fd400000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fd400000, 0x00000000fd400000, 0x00000000fd600000]
      [0.029s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fd600000, 0x00000000fd600000, 0x00000000fd800000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fd800000, 0x00000000fd800000, 0x00000000fda00000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fda00000, 0x00000000fda00000, 0x00000000fdc00000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fdc00000, 0x00000000fdc00000, 0x00000000fde00000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fde00000, 0x00000000fde00000, 0x00000000fe000000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fe000000, 0x00000000fe000000, 0x00000000fe200000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fe200000, 0x00000000fe200000, 0x00000000fe400000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fe400000, 0x00000000fe400000, 0x00000000fe600000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fe600000, 0x00000000fe600000, 0x00000000fe800000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fe800000, 0x00000000fe800000, 0x00000000fea00000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fea00000, 0x00000000fea00000, 0x00000000fec00000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fec00000, 0x00000000fec00000, 0x00000000fee00000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000fee00000, 0x00000000fee00000, 0x00000000ff000000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000ff000000, 0x00000000ff000000, 0x00000000ff200000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000ff200000, 0x00000000ff200000, 0x00000000ff400000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000ff400000, 0x00000000ff400000, 0x00000000ff600000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000ff600000, 0x00000000ff600000, 0x00000000ff800000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000ff800000, 0x00000000ff800000, 0x00000000ffa00000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000ffa00000, 0x00000000ffa00000, 0x00000000ffc00000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000ffc00000, 0x00000000ffc00000, 0x00000000ffe00000]
      [0.030s][trace][gc,region] G1HR COMMIT(FREE) [0x00000000ffe00000, 0x00000000ffe00000, 0x0000000100000000]
      [0.030s][trace][gc,alloc,region] Mutator Alloc Region: 0 NULL : initializing
      [0.030s][trace][gc,alloc,region] Mutator Alloc Region: 0 DUMMY : initialized
      [0.031s][info ][cds ] CDS archive was created with max heap size = 128M, and the following configuration:
      [0.031s][info ][cds ] narrow_klass_base = 0x0000000800000000, narrow_klass_shift = 3
      [0.031s][info ][cds ] narrow_oop_mode = 0, narrow_oop_base = 0x0000000000000000, narrow_oop_shift = 0
      [0.031s][info ][cds ] The current max heap size = 64M, HeapRegion::GrainBytes = 2097152
      [0.031s][info ][cds ] narrow_klass_base = 0x0000000800000000, narrow_klass_shift = 3
      [0.031s][info ][cds ] narrow_oop_mode = 0, narrow_oop_base = 0x0000000000000000, narrow_oop_shift = 0
      [0.031s][info ][cds ] CDS heap data relocation delta = 0 bytes
      [0.031s][info ][cds ] CDS heap data need to be relocated lower by a further 1048576 bytes to -1048576 to be aligned with HeapRegion::GrainBytes
      [0.031s][info ][cds ] Trying to map heap data: region[5] at 0x00000000ffc00000, size = 462848 bytes
      [0.031s][trace][gc,region ] G1HR ALLOC(CARC) [0x00000000ffc00000, 0x00000000ffc00000, 0x00000000ffe00000]
      [0.031s][info ][cds ] Trying to map heap data: region[7] at 0x00000000ffb00000, size = 278528 bytes
      [0.031s][trace][gc,region ] G1HR ALLOC(OARC) [0x00000000ffa00000, 0x00000000ffa00000, 0x00000000ffc00000]
      [0.070s][trace][gc,alloc,region] Mutator Alloc Region: 0 DUMMY : alloc failed min 256 desired 62916
      [0.070s][trace][gc,alloc,region] Mutator Alloc Region: 0 DUMMY : alloc failed min 62916 desired 62916
      [0.070s][trace][gc,alloc,region] Mutator Alloc Region: 0 DUMMY : retiring
      [0.070s][trace][gc,alloc,region] Mutator Alloc Region: 0 DUMMY : retired
      [0.070s][trace][gc,alloc,region] Mutator Alloc Region: 0 DUMMY : attempting region allocation
      [0.070s][trace][gc,region ] G1HR ALLOC(EDEN) [0x00000000ffe00000, 0x00000000ffe00000, 0x0000000100000000]
      [0.070s][trace][gc,alloc,region] Mutator Alloc Region: 0 DUMMY : update
      [0.070s][trace][gc,alloc,region] Mutator Alloc Region: 1 31:(E)[0x00000000ffe00000,0x00000000ffe7ae20,0x0000000100000000] : updated
      [0.070s][trace][gc,alloc,region] Mutator Alloc Region: 1 31:(E)[0x00000000ffe00000,0x00000000ffe7ae20,0x0000000100000000] : region allocation successful
      [0.070s][trace][gc,alloc,region] Mutator Alloc Region: 1 31:(E)[0x00000000ffe00000,0x00000000ffe7ae20,0x0000000100000000] : alloc locked (second attempt) min 62916 desired 62916 actual 62916 0x00000000ffe00000
      [0,251s][trace][gc,alloc,region] Mutator Alloc Region: 1 31:(E)[0x00000000ffe00000,0x00000000ffef5c98,0x0000000100000000] : alloc min 256 desired 62927 actual 62927 0x00000000ffe7ae20
      java version "12-internal" 2019-03-19
      Java(TM) SE Runtime Environment (slowdebug build 12-internal+0-2018-11-22-0909362.sjohanss...)
      Java HotSpot(TM) 64-Bit Server VM (slowdebug build 12-internal+0-2018-11-22-0909362.sjohanss..., mixed mode, sharing)
      [0,315s][trace][gc,alloc,region] Mutator Alloc Region: 1 31:(E)[0x00000000ffe00000,0x00000000fff70c20,0x0000000100000000] : alloc min 256 desired 62961 actual 62961 0x00000000ffef5c98

            iklam Ioi Lam
            jiangli Jiangli Zhou
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: