From 102b18acddf7ffaa962995dd961eee1230f67b3f Mon Sep 17 00:00:00 2001 From: Jochen Eisinger Date: Wed, 8 Apr 2015 14:29:17 +0200 Subject: [PATCH] When sweeping is in progress, either finalize or do nothing BUG=none LOG=n R=rmcilroy@chromium.org, hpayer@chromium.org Review URL: https://codereview.chromium.org/1070653003 Cr-Commit-Position: refs/branch-heads/4.3@{#4} Cr-Branched-From: f5c0a23a505616796a628d64f4ffe377d1fc4bcf-refs/heads/4.3.61@{#1} Cr-Branched-From: 0a7d4f496a554028de0ab5a963c3a004e693b4cb-refs/heads/master@{#27508} --- include/v8-version.h | 2 +- src/heap/gc-idle-time-handler.cc | 8 +++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/include/v8-version.h b/include/v8-version.h index 6b18e643b2c..74870bae6b1 100644 --- a/include/v8-version.h +++ b/include/v8-version.h @@ -11,7 +11,7 @@ #define V8_MAJOR_VERSION 4 #define V8_MINOR_VERSION 3 #define V8_BUILD_NUMBER 61 -#define V8_PATCH_LEVEL 2 +#define V8_PATCH_LEVEL 3 // Use 1 for candidates and 0 otherwise. // (Boolean macro values are not supported by all preprocessors.) diff --git a/src/heap/gc-idle-time-handler.cc b/src/heap/gc-idle-time-handler.cc index 250fb12ca0b..5060bc90d16 100644 --- a/src/heap/gc-idle-time-handler.cc +++ b/src/heap/gc-idle-time-handler.cc @@ -253,9 +253,11 @@ GCIdleTimeAction GCIdleTimeHandler::Compute(double idle_time_in_ms, } // TODO(hpayer): Estimate finalize sweeping time. - if (heap_state.sweeping_in_progress && - static_cast(idle_time_in_ms) >= kMinTimeForFinalizeSweeping) { - return GCIdleTimeAction::FinalizeSweeping(); + if (heap_state.sweeping_in_progress) { + if (static_cast(idle_time_in_ms) >= kMinTimeForFinalizeSweeping) { + return GCIdleTimeAction::FinalizeSweeping(); + } + return NothingOrDone(); } if (heap_state.incremental_marking_stopped &&