src/share/vm/memory/universe.cpp

Print this page
rev 4369 : 8010818: NPG: Remove metaspace memory pools


1091   Universe::_loader_addClass_cache->init(
1092     SystemDictionary::ClassLoader_klass(), m, CHECK_false);
1093 
1094   // The folowing is initializing converter functions for serialization in
1095   // JVM.cpp. If we clean up the StrictMath code above we may want to find
1096   // a better solution for this as well.
1097   initialize_converter_functions();
1098 
1099   // This needs to be done before the first scavenge/gc, since
1100   // it's an input to soft ref clearing policy.
1101   {
1102     MutexLocker x(Heap_lock);
1103     Universe::update_heap_info_at_gc();
1104   }
1105 
1106   // ("weak") refs processing infrastructure initialization
1107   Universe::heap()->post_initialize();
1108 
1109   // Initialize performance counters for metaspaces
1110   MetaspaceCounters::initialize_performance_counters();
1111   MemoryService::add_metaspace_memory_pools();
1112 
1113   GC_locker::unlock();  // allow gc after bootstrapping
1114 
1115   MemoryService::set_universe_heap(Universe::_collectedHeap);
1116   return true;
1117 }
1118 
1119 
1120 void Universe::compute_base_vtable_size() {
1121   _base_vtable_size = ClassLoader::compute_Object_vtable();
1122 }
1123 
1124 
1125 // %%% The Universe::flush_foo methods belong in CodeCache.
1126 
1127 // Flushes compiled methods dependent on dependee.
1128 void Universe::flush_dependents_on(instanceKlassHandle dependee) {
1129   assert_lock_strong(Compile_lock);
1130 
1131   if (CodeCache::number_of_nmethods_with_dependencies() == 0) return;




1091   Universe::_loader_addClass_cache->init(
1092     SystemDictionary::ClassLoader_klass(), m, CHECK_false);
1093 
1094   // The folowing is initializing converter functions for serialization in
1095   // JVM.cpp. If we clean up the StrictMath code above we may want to find
1096   // a better solution for this as well.
1097   initialize_converter_functions();
1098 
1099   // This needs to be done before the first scavenge/gc, since
1100   // it's an input to soft ref clearing policy.
1101   {
1102     MutexLocker x(Heap_lock);
1103     Universe::update_heap_info_at_gc();
1104   }
1105 
1106   // ("weak") refs processing infrastructure initialization
1107   Universe::heap()->post_initialize();
1108 
1109   // Initialize performance counters for metaspaces
1110   MetaspaceCounters::initialize_performance_counters();

1111 
1112   GC_locker::unlock();  // allow gc after bootstrapping
1113 
1114   MemoryService::set_universe_heap(Universe::_collectedHeap);
1115   return true;
1116 }
1117 
1118 
1119 void Universe::compute_base_vtable_size() {
1120   _base_vtable_size = ClassLoader::compute_Object_vtable();
1121 }
1122 
1123 
1124 // %%% The Universe::flush_foo methods belong in CodeCache.
1125 
1126 // Flushes compiled methods dependent on dependee.
1127 void Universe::flush_dependents_on(instanceKlassHandle dependee) {
1128   assert_lock_strong(Compile_lock);
1129 
1130   if (CodeCache::number_of_nmethods_with_dependencies() == 0) return;