From 052cd2556f312bbf37d4aa7c53f282d3ec300d9a Mon Sep 17 00:00:00 2001 From: "hpayer@chromium.org" Date: Fri, 19 Sep 2014 07:51:23 +0000 Subject: [PATCH] Perform scavenges only for small idle times. BUG= R=jochen@chromium.org Review URL: https://codereview.chromium.org/586643002 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24066 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- src/heap/gc-idle-time-handler.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/heap/gc-idle-time-handler.cc b/src/heap/gc-idle-time-handler.cc index 7c74dcb..b9a99b2 100644 --- a/src/heap/gc-idle-time-handler.cc +++ b/src/heap/gc-idle-time-handler.cc @@ -110,7 +110,8 @@ bool GCIdleTimeHandler::ScavangeMayHappenSoon( // that this currently may trigger a full garbage collection. GCIdleTimeAction GCIdleTimeHandler::Compute(size_t idle_time_in_ms, HeapState heap_state) { - if (ScavangeMayHappenSoon( + if (idle_time_in_ms <= kMaxFrameRenderingIdleTime && + ScavangeMayHappenSoon( heap_state.available_new_space_memory, heap_state.new_space_allocation_throughput_in_bytes_per_ms) && idle_time_in_ms >= -- 2.7.4