diff options
-rw-r--r-- | runtime/gc/heap.cc | 3 | ||||
-rw-r--r-- | runtime/gc/heap.h | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/runtime/gc/heap.cc b/runtime/gc/heap.cc index 17913fc2dc..cb4360171a 100644 --- a/runtime/gc/heap.cc +++ b/runtime/gc/heap.cc @@ -3453,7 +3453,8 @@ void Heap::GrowForUtilization(collector::GarbageCollector* collector_ran, if (gc_type != collector::kGcTypeSticky) { // Grow the heap for non sticky GC. ssize_t delta = bytes_allocated / GetTargetHeapUtilization() - bytes_allocated; - CHECK_GE(delta, 0); + CHECK_GE(delta, 0) << "bytes_allocated=" << bytes_allocated + << " target_utilization_=" << target_utilization_; target_size = bytes_allocated + delta * multiplier; target_size = std::min(target_size, bytes_allocated + adjusted_max_free); target_size = std::max(target_size, bytes_allocated + adjusted_min_free); diff --git a/runtime/gc/heap.h b/runtime/gc/heap.h index 7fb634fcf7..9d2d2ed514 100644 --- a/runtime/gc/heap.h +++ b/runtime/gc/heap.h @@ -1331,7 +1331,7 @@ class Heap { // The ideal maximum free size, when we grow the heap for utilization. size_t max_free_; - // Target ideal heap utilization ratio + // Target ideal heap utilization ratio. double target_utilization_; // How much more we grow the heap when we are a foreground app instead of background. |