// Register the amount of external allocated memory.
amount_of_external_allocated_memory_at_last_global_gc_ =
amount_of_external_allocated_memory_;
- SetOldGenerationAllocationLimit(old_gen_size, gc_speed, mutator_speed,
- freed_global_handles);
+ SetOldGenerationAllocationLimit(old_gen_size, gc_speed, mutator_speed);
} else if (HasLowYoungGenerationAllocationRate() &&
old_generation_size_configured_) {
DampenOldGenerationAllocationLimit(old_gen_size, gc_speed, mutator_speed);
void Heap::SetOldGenerationAllocationLimit(intptr_t old_gen_size,
double gc_speed,
- double mutator_speed,
- int freed_global_handles) {
- const int kFreedGlobalHandlesThreshold = 700;
+ double mutator_speed) {
const double kConservativeHeapGrowingFactor = 1.3;
double factor = HeapGrowingFactor(gc_speed, mutator_speed);
factor = Min(factor, kMaxHeapGrowingFactorMemoryConstrained);
}
- if (freed_global_handles >= kFreedGlobalHandlesThreshold ||
- memory_reducer_.ShouldGrowHeapSlowly() || optimize_for_memory_usage_) {
+ if (memory_reducer_.ShouldGrowHeapSlowly() || optimize_for_memory_usage_) {
factor = Min(factor, kConservativeHeapGrowingFactor);
}
// Sets the allocation limit to trigger the next full garbage collection.
void SetOldGenerationAllocationLimit(intptr_t old_gen_size, double gc_speed,
- double mutator_speed,
- int freed_global_handles);
+ double mutator_speed);
// Decrease the allocation limit if the new limit based on the given
// parameters is lower than the current limit.