diff src/share/vm/gc_implementation/parallelScavenge/psAdaptiveSizePolicy.hpp @ 14909:4ca6dc0799b6

Backout jdk9 merge
author Gilles Duboscq <duboscq@ssw.jku.at>
date Tue, 01 Apr 2014 13:57:07 +0200
parents 44315152d434
children 52b4284cb496
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/parallelScavenge/psAdaptiveSizePolicy.hpp	Tue Apr 01 14:09:03 2014 +0200
+++ b/src/share/vm/gc_implementation/parallelScavenge/psAdaptiveSizePolicy.hpp	Tue Apr 01 13:57:07 2014 +0200
@@ -37,7 +37,7 @@
 //
 // It also computes an optimal tenuring threshold between the young
 // and old generations, so as to equalize the cost of collections
-// of those generations, as well as optimal survivor space sizes
+// of those generations, as well as optimial survivor space sizes
 // for the young generation.
 //
 // While this class is specifically intended for a generational system
@@ -113,7 +113,7 @@
   // Changing the generation sizing depends on the data that is
   // gathered about the effects of changes on the pause times and
   // throughput.  These variable count the number of data points
-  // gathered.  The policy may use these counters as a threshold
+  // gathered.  The policy may use these counters as a threshhold
   // for reliable data.
   julong _young_gen_change_for_major_pause_count;
 
@@ -240,6 +240,7 @@
   void major_collection_begin();
   void major_collection_end(size_t amount_live, GCCause::Cause gc_cause);
 
+  //
   void tenured_allocation(size_t size) {
     _avg_pretenured->sample(size);
   }
@@ -247,9 +248,9 @@
   // Accessors
   // NEEDS_CLEANUP   should use sizes.hpp
 
-  static size_t calculate_free_based_on_live(size_t live, uintx ratio_as_percentage);
-
-  size_t calculated_old_free_size_in_bytes() const;
+  size_t calculated_old_free_size_in_bytes() const {
+    return (size_t)(_promo_size + avg_promoted()->padded_average());
+  }
 
   size_t average_old_live_in_bytes() const {
     return (size_t) avg_old_live()->average();