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

CDS: Make sure the ArchiveRelocationMode is always printed in the log

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 25
    • None
    • hotspot
    • master

      It seems like we don't always print the ArchiveRelocationMode (at least, when it's default, i.e. 1). A quote from [~ccheung]:

      "If MetaspaceShared::map_archives() returns early, then the "ArchiveRelocationMode ==1" won't appear in the output."

      Here's a correct sample output line, which we expect:

      [0.034s][info][cds] ArchiveRelocationMode == 1: always map archive(s) at an alternative address

      Log messages provide important troubleshooting information and should not be printed probabilistically or avoided on certain execution paths only. This also violates the least astonishment principle.

      AFAIU, we're talking about the 'MapArchiveResult MetaspaceShared::map_archives' defined in the 'hotspot/share/cds/metaspaceShared.cpp'.

            ccheung Calvin Cheung
            enikitin Evgeny Nikitin
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: