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

Unified Diff: src/heap/incremental-marking.h

Issue 894703002: Add a flag to over approximate the weak closure during GC (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 11 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/incremental-marking.h
diff --git a/src/heap/incremental-marking.h b/src/heap/incremental-marking.h
index 56c5a24c2ceb732ab90bc1865da5bf184e5f46f8..63a708b69b208cd07789b12d3217c958a0558928 100644
--- a/src/heap/incremental-marking.h
+++ b/src/heap/incremental-marking.h
@@ -36,6 +36,13 @@ class IncrementalMarking {
bool should_hurry() { return should_hurry_; }
void set_should_hurry(bool val) { should_hurry_ = val; }
+ bool weak_closure_was_overapproximated() const {
+ return weak_closure_was_overapproximated_;
+ }
+ void set_weak_closure_was_overapproximated(bool val) {
+ weak_closure_was_overapproximated_ = val;
+ }
+
inline bool IsStopped() { return state() == STOPPED; }
INLINE(bool IsMarking()) { return state() >= MARKING; }
@@ -102,6 +109,7 @@ class IncrementalMarking {
inline void RestartIfNotMarking() {
if (state_ == COMPLETE) {
state_ = MARKING;
+ weak_closure_was_overapproximated_ = false;
if (FLAG_trace_incremental_marking) {
PrintF("[IncrementalMarking] Restarting (new grey objects)\n");
}
@@ -228,6 +236,8 @@ class IncrementalMarking {
bool was_activated_;
+ bool weak_closure_was_overapproximated_;
+
DISALLOW_IMPLICIT_CONSTRUCTORS(IncrementalMarking);
};
}

Powered by Google App Engine
This is Rietveld 408576698