68 GCH_PS_ObjectSynchronizer_oops_do, 69 GCH_PS_FlatProfiler_oops_do, 70 GCH_PS_Management_oops_do, 71 GCH_PS_SystemDictionary_oops_do, 72 GCH_PS_ClassLoaderDataGraph_oops_do, 73 GCH_PS_jvmti_oops_do, 74 GCH_PS_CodeCache_oops_do, 75 GCH_PS_younger_gens, 76 // Leave this one last. 77 GCH_PS_NumElements 78 }; 79 80 GenCollectedHeap::GenCollectedHeap(GenCollectorPolicy *policy) : 81 SharedHeap(), 82 _rem_set(NULL), 83 _gen_policy(policy), 84 _process_strong_tasks(new SubTasksDone(GCH_PS_NumElements)), 85 _full_collections_completed(0) 86 { 87 assert(policy != NULL, "Sanity check"); 88 } 89 90 jint GenCollectedHeap::initialize() { 91 CollectedHeap::pre_initialize(); 92 93 _n_gens = gen_policy()->number_of_generations(); 94 assert(_n_gens == 2, "There is no support for more than two generations"); 95 96 // While there are no constraints in the GC code that HeapWordSize 97 // be any particular value, there are multiple other areas in the 98 // system which believe this to be true (e.g. oop->object_size in some 99 // cases incorrectly returns the size in wordSize units rather than 100 // HeapWordSize). 101 guarantee(HeapWordSize == wordSize, "HeapWordSize must equal wordSize"); 102 103 // Allocate space for the heap. 104 105 char* heap_address; 106 ReservedSpace heap_rs; 107 | 68 GCH_PS_ObjectSynchronizer_oops_do, 69 GCH_PS_FlatProfiler_oops_do, 70 GCH_PS_Management_oops_do, 71 GCH_PS_SystemDictionary_oops_do, 72 GCH_PS_ClassLoaderDataGraph_oops_do, 73 GCH_PS_jvmti_oops_do, 74 GCH_PS_CodeCache_oops_do, 75 GCH_PS_younger_gens, 76 // Leave this one last. 77 GCH_PS_NumElements 78 }; 79 80 GenCollectedHeap::GenCollectedHeap(GenCollectorPolicy *policy) : 81 SharedHeap(), 82 _rem_set(NULL), 83 _gen_policy(policy), 84 _process_strong_tasks(new SubTasksDone(GCH_PS_NumElements)), 85 _full_collections_completed(0) 86 { 87 assert(policy != NULL, "Sanity check"); 88 if (UseConcMarkSweepGC) { 89 _workers = new FlexibleWorkGang("GC Thread", ParallelGCThreads, 90 /* are_GC_task_threads */true, 91 /* are_ConcurrentGC_threads */false); 92 _workers->initialize_workers(); 93 } else { 94 _workers = NULL; 95 } 96 } 97 98 jint GenCollectedHeap::initialize() { 99 CollectedHeap::pre_initialize(); 100 101 _n_gens = gen_policy()->number_of_generations(); 102 assert(_n_gens == 2, "There is no support for more than two generations"); 103 104 // While there are no constraints in the GC code that HeapWordSize 105 // be any particular value, there are multiple other areas in the 106 // system which believe this to be true (e.g. oop->object_size in some 107 // cases incorrectly returns the size in wordSize units rather than 108 // HeapWordSize). 109 guarantee(HeapWordSize == wordSize, "HeapWordSize must equal wordSize"); 110 111 // Allocate space for the heap. 112 113 char* heap_address; 114 ReservedSpace heap_rs; 115 |