Index: src/heap/heap.cc |
diff --git a/src/heap/heap.cc b/src/heap/heap.cc |
index d4cd78ebdaa7f1161ff56ea45a5cfdf6f6fe3e8e..a67bf050b2ee2aa6c677aff8d1cd308d05f654ea 100644 |
--- a/src/heap/heap.cc |
+++ b/src/heap/heap.cc |
@@ -1092,8 +1092,6 @@ void Heap::UpdateSurvivalStatistics(int start_new_space_size) { |
promotion_ratio_ = (static_cast<double>(promoted_objects_size_) / |
static_cast<double>(start_new_space_size) * 100); |
- if (gc_count_ > 1) tracer()->AddPromotionRatio(promotion_ratio_); |
- |
if (previous_semi_space_copied_object_size_ > 0) { |
promotion_rate_ = |
(static_cast<double>(promoted_objects_size_) / |
@@ -1107,6 +1105,7 @@ void Heap::UpdateSurvivalStatistics(int start_new_space_size) { |
static_cast<double>(start_new_space_size) * 100); |
double survival_rate = promotion_ratio_ + semi_space_copied_rate_; |
+ tracer()->AddSurvivalRatio(survival_rate); |
if (survival_rate > kYoungSurvivalRateHighThreshold) { |
high_survival_rate_period_length_++; |
} else { |
@@ -2418,8 +2417,8 @@ void Heap::ConfigureInitialOldGenerationSize() { |
old_generation_allocation_limit_ = |
Max(kMinimumOldGenerationAllocationLimit, |
static_cast<intptr_t>( |
- static_cast<double>(initial_old_generation_size_) * |
- (tracer()->AveragePromotionRatio() / 100))); |
+ static_cast<double>(old_generation_allocation_limit_) * |
+ (tracer()->AverageSurvivalRatio() / 100))); |
} |
} |