hotspot/src/share/vm/memory/genCollectedHeap.cpp
changeset 4637 af4d405aacc1
parent 3908 24b55ad4c228
child 4641 02adf6837856
equal deleted inserted replaced
4636:90e004691873 4637:af4d405aacc1
    49   assert(policy != NULL, "Sanity check");
    49   assert(policy != NULL, "Sanity check");
    50   _preloading_shared_classes = false;
    50   _preloading_shared_classes = false;
    51 }
    51 }
    52 
    52 
    53 jint GenCollectedHeap::initialize() {
    53 jint GenCollectedHeap::initialize() {
       
    54   CollectedHeap::pre_initialize();
       
    55 
    54   int i;
    56   int i;
    55   _n_gens = gen_policy()->number_of_generations();
    57   _n_gens = gen_policy()->number_of_generations();
    56 
    58 
    57   // While there are no constraints in the GC code that HeapWordSize
    59   // While there are no constraints in the GC code that HeapWordSize
    58   // be any particular value, there are multiple other areas in the
    60   // be any particular value, there are multiple other areas in the
   127                                            - perm_gen_spec->misc_code_size();
   129                                            - perm_gen_spec->misc_code_size();
   128   _reserved.set_end((HeapWord*)(heap_rs.base() + actual_heap_size));
   130   _reserved.set_end((HeapWord*)(heap_rs.base() + actual_heap_size));
   129 
   131 
   130   _rem_set = collector_policy()->create_rem_set(_reserved, n_covered_regions);
   132   _rem_set = collector_policy()->create_rem_set(_reserved, n_covered_regions);
   131   set_barrier_set(rem_set()->bs());
   133   set_barrier_set(rem_set()->bs());
       
   134 
   132   _gch = this;
   135   _gch = this;
   133 
   136 
   134   for (i = 0; i < _n_gens; i++) {
   137   for (i = 0; i < _n_gens; i++) {
   135     ReservedSpace this_rs = heap_rs.first_part(_gen_specs[i]->max_size(),
   138     ReservedSpace this_rs = heap_rs.first_part(_gen_specs[i]->max_size(),
   136                                               UseSharedSpaces, UseSharedSpaces);
   139                                               UseSharedSpaces, UseSharedSpaces);