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

Unified Diff: src/heap/heap.cc

Issue 2735803005: [heap] Start concurrent marking simultaneously with incremental marking. (Closed)
Patch Set: tweak Created 3 years, 9 months 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
Index: src/heap/heap.cc
diff --git a/src/heap/heap.cc b/src/heap/heap.cc
index 2bf98a857ec56003be304d07332f6d4c04283187..d203a19b43e549cb7af7b434b70e43680bbfc847 100644
--- a/src/heap/heap.cc
+++ b/src/heap/heap.cc
@@ -1344,8 +1344,10 @@ bool Heap::PerformGarbageCollection(
MinorMarkCompact();
break;
case SCAVENGER:
- if (fast_promotion_mode_ &&
- CanExpandOldGeneration(new_space()->Size())) {
+ if ((fast_promotion_mode_ &&
+ CanExpandOldGeneration(new_space()->Size())) ||
+ (FLAG_concurrent_marking &&
+ concurrent_marking_->IsMarkingInProgress())) {
Michael Lippautz 2017/03/08 19:14:34 IsMarkingInProgress should imply FLAG_concurrent_m
ulan 2017/03/10 16:45:27 Done.
tracer()->NotifyYoungGenerationHandling(
YoungGenerationHandling::kFastPromotionDuringScavenge);
EvacuateYoungGeneration();
@@ -1603,8 +1605,10 @@ class ScavengeWeakObjectRetainer : public WeakObjectRetainer {
void Heap::EvacuateYoungGeneration() {
TRACE_GC(tracer(), GCTracer::Scope::SCAVENGER_EVACUATE);
- DCHECK(fast_promotion_mode_);
- DCHECK(CanExpandOldGeneration(new_space()->Size()));
+ if (!FLAG_concurrent_marking) {
+ DCHECK(fast_promotion_mode_);
+ DCHECK(CanExpandOldGeneration(new_space()->Size()));
+ }
mark_compact_collector()->sweeper().EnsureNewSpaceCompleted();

Powered by Google App Engine
This is Rietveld 408576698