hotspot/src/share/vm/classfile/systemDictionary.cpp
changeset 46689 59f0972cf342
parent 46560 388aa8d67c80
child 46701 f559541c0daa
equal deleted inserted replaced
46687:9843d494abd5 46689:59f0972cf342
  2120   ClassLoader::classLoader_init2(CHECK);
  2120   ClassLoader::classLoader_init2(CHECK);
  2121 
  2121 
  2122   // Preload commonly used klasses
  2122   // Preload commonly used klasses
  2123   WKID scan = FIRST_WKID;
  2123   WKID scan = FIRST_WKID;
  2124   // first do Object, then String, Class
  2124   // first do Object, then String, Class
       
  2125 #if INCLUDE_CDS
  2125   if (UseSharedSpaces) {
  2126   if (UseSharedSpaces) {
  2126     initialize_wk_klasses_through(WK_KLASS_ENUM_NAME(Object_klass), scan, CHECK);
  2127     initialize_wk_klasses_through(WK_KLASS_ENUM_NAME(Object_klass), scan, CHECK);
  2127     // Initialize the constant pool for the Object_class
  2128     // Initialize the constant pool for the Object_class
  2128     Object_klass()->constants()->restore_unshareable_info(CHECK);
  2129     Object_klass()->constants()->restore_unshareable_info(CHECK);
  2129     initialize_wk_klasses_through(WK_KLASS_ENUM_NAME(Class_klass), scan, CHECK);
  2130     initialize_wk_klasses_through(WK_KLASS_ENUM_NAME(Class_klass), scan, CHECK);
  2130   } else {
  2131   } else
       
  2132 #endif
       
  2133   {
  2131     initialize_wk_klasses_through(WK_KLASS_ENUM_NAME(Class_klass), scan, CHECK);
  2134     initialize_wk_klasses_through(WK_KLASS_ENUM_NAME(Class_klass), scan, CHECK);
  2132   }
  2135   }
  2133 
  2136 
  2134   // Calculate offsets for String and Class classes since they are loaded and
  2137   // Calculate offsets for String and Class classes since they are loaded and
  2135   // can be used after this point.
  2138   // can be used after this point.