Use a higher-level function to store Strings into CDS archive

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Won't Fix
    • Priority: P4
    • None
    • Affects Version/s: None
    • Component/s: hotspot

      See http://hg.openjdk.java.net/jdk/jdk/file/fab77e2d8146/src/hotspot/share/classfile/stringTable.cpp#l784

      StringTable::create_archived_string() has intimate knowledge of the internal layout of String objects, and archive each reference field manually. This is cumbersome and will need to be updated if we ever change the String layout.

      We should use a variant of HeapShared::archive_reachable_objects_from() which already archiving objects with arbitrary layout.

            Assignee:
            Ioi Lam
            Reporter:
            Ioi Lam
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: