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

Unified Diff: Source/platform/heap/ThreadState.h

Issue 1190513006: Oilpan: adjust GC policy under memory pressure (only.) (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: remove testing CPPery Created 5 years, 6 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
« no previous file with comments | « Source/bindings/core/v8/V8GCController.cpp ('k') | Source/platform/heap/ThreadState.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/heap/ThreadState.h
diff --git a/Source/platform/heap/ThreadState.h b/Source/platform/heap/ThreadState.h
index 140fef86118bcbbdaadd7ba36a618be1ed3dd2c5..481455f76ba068a19a56142693ff03493579dffc 100644
--- a/Source/platform/heap/ThreadState.h
+++ b/Source/platform/heap/ThreadState.h
@@ -315,7 +315,7 @@ public:
bool isMainThread() const { return this == mainThreadState(); }
void checkThread() const { ASSERT(m_thread == currentThread()); }
- void didV8GC();
+ void didV8MajorGC();
void performIdleGC(double deadlineSeconds);
void performIdleLazySweep(double deadlineSeconds);
@@ -652,13 +652,18 @@ private:
// shouldSchedule{Precise,Idle}GC and shouldForceConservativeGC
// implement the heuristics that are used to determine when to collect garbage.
// If shouldForceConservativeGC returns true, we force the garbage
- // collection immediately. Otherwise, if shouldGC returns true, we
+ // collection immediately. Otherwise, if should*GC returns true, we
// record that we should garbage collect the next time we return
// to the event loop. If both return false, we don't need to
// collect garbage at this point.
bool shouldScheduleIdleGC();
bool shouldSchedulePreciseGC();
bool shouldForceConservativeGC();
+
+ // Internal helper for GC policy handling code. Returns true if
+ // an urgent conservative GC is now needed due to memory pressure.
+ bool shouldForceMemoryPressureGC();
+
void runScheduledGC(StackState);
void eagerSweep();
« no previous file with comments | « Source/bindings/core/v8/V8GCController.cpp ('k') | Source/platform/heap/ThreadState.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698