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

Unified Diff: Source/heap/ThreadState.h

Issue 220203005: Oilpan: introduce sticky forcedForTesting flag to ensure that a precise (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 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: Source/heap/ThreadState.h
diff --git a/Source/heap/ThreadState.h b/Source/heap/ThreadState.h
index 3e799158c144d011152f6ef167165fbfacc7b935..9671e111f78b11a192d731838da9a0fe1e0920f6 100644
--- a/Source/heap/ThreadState.h
+++ b/Source/heap/ThreadState.h
@@ -278,6 +278,17 @@ public:
void setGCRequested();
void clearGCRequested();
+ void performPendingGC(StackState);
wibling-chromium 2014/04/01 13:26:09 NIT: Could be made private.
Mads Ager (chromium) 2014/04/01 13:45:38 Done.
+
+ // Was the last GC forced for testing? This is set when garbage collection
+ // is forced for testing and there are pointers on the stack. It remains
+ // set until a garbage collection is triggered with no pointers on the stack.
+ // This is used for layout tests that trigger GCs and check if objects are
+ // dead at a given point in time. That only reliably works when we get
+ // precise GCs with no conservative stack scanning.
+ void setForcedForTesting(bool);
+ bool forcedForTesting();
wibling-chromium 2014/04/01 13:26:09 NIT: Could be made private.
Mads Ager (chromium) 2014/04/01 13:45:38 This one is called from Heap. We could make heap a
+
bool sweepRequested();
void setSweepRequested();
void clearSweepRequested();
@@ -540,6 +551,7 @@ private:
bool m_atSafePoint;
Vector<Interruptor*> m_interruptors;
bool m_gcRequested;
+ bool m_forcedForTesting;
volatile int m_sweepRequested;
bool m_sweepInProgress;
size_t m_noAllocationCount;

Powered by Google App Engine
This is Rietveld 408576698