| Index: src/heap/gc-idle-time-handler.cc
|
| diff --git a/src/heap/gc-idle-time-handler.cc b/src/heap/gc-idle-time-handler.cc
|
| index 0a174d533db9be28da9c3f31c249cc2a35a24848..e88710bd1d10533c8905aab3ef1a8422e95feba2 100644
|
| --- a/src/heap/gc-idle-time-handler.cc
|
| +++ b/src/heap/gc-idle-time-handler.cc
|
| @@ -399,7 +399,8 @@ GCIdleTimeHandler::Mode GCIdleTimeHandler::NextMode(
|
| }
|
| break;
|
| case kReduceMemory:
|
| - if (idle_mark_compacts_ >= kMaxIdleMarkCompacts) {
|
| + if (idle_mark_compacts_ >= kMaxIdleMarkCompacts ||
|
| + (idle_mark_compacts_ > 0 && !next_gc_likely_to_collect_more_)) {
|
| return kDone;
|
| }
|
| if (mutator_gcs > idle_mark_compacts_) {
|
|
|