Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1086)

Unified Diff: src/heap/heap.cc

Issue 2521983002: [heap] Force finalization of incremental MC when close to OOM. (Closed)
Patch Set: [heap] Force finalization of incremental MC when close to OOM. Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/heap.cc
diff --git a/src/heap/heap.cc b/src/heap/heap.cc
index 9a1df48698cd4e7e84b5e424df26e562a73a95ed..6c670ac53cba367200b2958456cddeb6faad8adc 100644
--- a/src/heap/heap.cc
+++ b/src/heap/heap.cc
@@ -956,10 +956,11 @@ bool Heap::CollectGarbage(GarbageCollector collector,
}
}
- if (collector == MARK_COMPACTOR && !ShouldFinalizeIncrementalMarking() &&
- !ShouldAbortIncrementalMarking() && !incremental_marking()->IsStopped() &&
- !incremental_marking()->should_hurry() && FLAG_incremental_marking &&
- OldGenerationSpaceAvailable() <= 0) {
+ if (collector == MARK_COMPACTOR && FLAG_incremental_marking &&
+ !ShouldFinalizeIncrementalMarking() && !ShouldAbortIncrementalMarking() &&
+ !incremental_marking()->IsStopped() &&
+ !incremental_marking()->should_hurry() &&
+ !IsCloseToOutOfMemory(new_space_->Capacity())) {
if (!incremental_marking()->IsComplete() &&
!mark_compact_collector()->marking_deque()->IsEmpty() &&
!FLAG_gc_global) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698