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

Change log_info(cds) to `MetaspaceShared::report_loading_error()`

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P4 P4
    • None
    • None
    • hotspot

      There are many AOT cache loading failures that are logged to the "info" channel. The the historical reason is described in JDK-8327495 (to avoid excessive warnings when using the default CDS archive).

      We have some remaining logs that should be changed from log_info(cds) to the MetaspaceShared::report_loading_error() function introduced in JDK-8327495, so that users can be become more aware of the issues when using an AOT cache.

      E.g.,

      https://github.com/openjdk/jdk/blob/45dfc2c6d6d6b2b0749347b0150bb22d49f12767/src/hotspot/share/cds/filemap.cpp#L1904-L1906

        if (_obj_alignment != ObjectAlignmentInBytes) {
          log_info(cds)("The %s's ObjectAlignmentInBytes of %d"
                        " does not equal the current ObjectAlignmentInBytes of %d.",
                        file_type, _obj_alignment, ObjectAlignmentInBytes);
          return false;
        }

            Unassigned Unassigned
            iklam Ioi Lam
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: