1.1 --- a/src/share/vm/memory/defNewGeneration.cpp Mon Jan 14 09:58:52 2013 +0100 1.2 +++ b/src/share/vm/memory/defNewGeneration.cpp Mon Jan 14 21:30:45 2013 +0100 1.3 @@ -550,6 +550,11 @@ 1.4 return allocate(size, is_tlab); 1.5 } 1.6 1.7 +void DefNewGeneration::adjust_desired_tenuring_threshold() { 1.8 + // Set the desired survivor size to half the real survivor space 1.9 + _tenuring_threshold = 1.10 + age_table()->compute_tenuring_threshold(to()->capacity()/HeapWordSize); 1.11 +} 1.12 1.13 void DefNewGeneration::collect(bool full, 1.14 bool clear_all_soft_refs, 1.15 @@ -649,9 +654,7 @@ 1.16 1.17 assert(to()->is_empty(), "to space should be empty now"); 1.18 1.19 - // Set the desired survivor size to half the real survivor space 1.20 - _tenuring_threshold = 1.21 - age_table()->compute_tenuring_threshold(to()->capacity()/HeapWordSize); 1.22 + adjust_desired_tenuring_threshold(); 1.23 1.24 // A successful scavenge should restart the GC time limit count which is 1.25 // for full GC's.