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

Relax the order requirement in SystemDictionary::initialize_well_known_classes

    Details

    • Type: Enhancement
    • Status: Closed
    • Priority: P4
    • Resolution: Won't Fix
    • Affects Version/s: 12
    • Fix Version/s: tbd
    • Component/s: hotspot
    • Labels:
      None

      Description

      This comment in systemDictionary.hpp may be too scary than necessary:

      // Certain classes, such as java.lang.Object and java.lang.String,
      // are "well-known", in the sense that no class loader is allowed
      // to provide a different definition.
      //
      // Each well-known class has a short klass name (like object_klass),
      // and a vmSymbol name (like java_lang_Object).
      //
      // The order of these definitions is significant: the classes are
      // resolved during early VM start-up by resolve_well_known_classes
      // in this order. Changing the order may require careful restructuring
      // of the VM start-up sequence.
      //

      The order of the first few classes resolved in initialize_well_known_classes() is important, as the creation of Object, Serializable, Cloneable, String, etc, have to be done in a certain order.

      I'm not sure about the order of the reference classes, 292 classes, and box classes are important. I'll experiment of getting rid of the separate phases after the call to Universe::fixup_mirrors(). This might be relics from old days where the classes were once indeed initialized in SystemDictionary::initialize_well_known_classes, which was the old name for SystemDictionary::resolve_well_known_classes.

        Attachments

          Activity

            People

            • Assignee:
              iklam Ioi Lam
              Reporter:
              iklam Ioi Lam
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: