Index: runtime/vm/scavenger.h |
diff --git a/runtime/vm/scavenger.h b/runtime/vm/scavenger.h |
index 160354a1413bab283b6c01ea77e9aaecb7bc1151..36f4f4880787537182ee38475a541e94dbcfbb40 100644 |
--- a/runtime/vm/scavenger.h |
+++ b/runtime/vm/scavenger.h |
@@ -98,6 +98,8 @@ class ScavengeStats { |
: 0.0; |
} |
+ intptr_t UsedBeforeInWords() const { return before_.used_in_words; } |
+ |
int64_t DurationMicros() const { return end_micros_ - start_micros_; } |
private: |
@@ -222,6 +224,8 @@ class Scavenger { |
void WriteProtect(bool read_only); |
+ bool ShouldPerformIdleScavenge(int64_t deadline); |
+ |
void AddGCTime(int64_t micros) { gc_time_micros_ += micros; } |
int64_t gc_time_micros() const { return gc_time_micros_; } |
@@ -331,9 +335,12 @@ class Scavenger { |
int64_t gc_time_micros_; |
intptr_t collections_; |
- static const int kStatsHistoryCapacity = 2; |
+ static const int kStatsHistoryCapacity = 4; |
RingBuffer<ScavengeStats, kStatsHistoryCapacity> stats_history_; |
+ intptr_t scavenge_words_per_micro_; |
+ intptr_t idle_scavenge_threshold_in_words_; |
+ |
// The total size of external data associated with objects in this scavenger. |
intptr_t external_size_; |