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

Unified Diff: third_party/WebKit/Source/platform/heap/ThreadState.cpp

Issue 1369783002: Reinstate memory pressure Oilpan GC check post V8 major GCs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/platform/heap/ThreadState.cpp
diff --git a/third_party/WebKit/Source/platform/heap/ThreadState.cpp b/third_party/WebKit/Source/platform/heap/ThreadState.cpp
index 4a1efe48e8904b9f5bcf581155bcf3d28980ee82..92148179428fb84048c98097305c44fffdcfd20a 100644
--- a/third_party/WebKit/Source/platform/heap/ThreadState.cpp
+++ b/third_party/WebKit/Source/platform/heap/ThreadState.cpp
@@ -678,6 +678,13 @@ void ThreadState::scheduleV8FollowupGCIfNeeded(V8GCType gcType)
if (isGCForbidden())
return;
+ // If V8 has acted on a memory pressure signal and performed a major GC,
+ // follow up, if needed.
+ if (gcType == V8MajorGC && shouldForceMemoryPressureGC()) {
haraken 2015/09/26 02:04:37 A better form would be: if (shouldForceMemoryPres
haraken 2015/09/26 02:04:37 Is there any reason we want to limit this to V8Maj
sof 2015/09/26 06:17:22 v8 will force major GCs on detecting/being signall
sof 2015/09/26 06:17:22 We've been over that two-step formulation before i
sof 2015/09/26 06:17:22 Done.
+ Heap::collectGarbage(HeapPointersOnStack, GCWithoutSweep, Heap::ConservativeGC);
+ return;
+ }
+
if (isSweepingInProgress())
return;
ASSERT(!sweepForbidden());
« 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