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

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

Issue 1963453002: Accurately measure current persistent count while running termination GC. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 5e5bd450d6c5a777f7cc93eb5eceb087ed63c79f..f11c93be01d7ae46318b0a448654beddbc2b995f 100644
--- a/third_party/WebKit/Source/platform/heap/ThreadState.cpp
+++ b/third_party/WebKit/Source/platform/heap/ThreadState.cpp
@@ -222,6 +222,8 @@ void ThreadState::runTerminationGC()
// Finish sweeping.
completeSweep();
+ releaseStaticPersistentNodes();
+
// From here on ignore all conservatively discovered
// pointers into the heap owned by this thread.
m_isTerminating = true;
@@ -239,10 +241,10 @@ void ThreadState::runTerminationGC()
int currentCount = getPersistentRegion()->numberOfPersistents();
ASSERT(currentCount >= 0);
while (currentCount != oldCount) {
- // Release the thread-local static persistents, including any
- // that are instantiated while running the termination GCs.
- releaseStaticPersistentNodes();
ThreadHeap::collectGarbageForTerminatingThread(this);
+ // Release the thread-local static persistents that were
+ // instantiated while running the termination GC.
+ releaseStaticPersistentNodes();
oldCount = currentCount;
currentCount = getPersistentRegion()->numberOfPersistents();
}
« 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