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

Unified Diff: src/mark-compact.cc

Issue 12261011: Move sweeping pending status field of concurrent sweepers to MarkCompactCollector. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 10 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 | « src/mark-compact.h ('k') | src/sweeper-thread.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/mark-compact.cc
diff --git a/src/mark-compact.cc b/src/mark-compact.cc
index e828f9c7ce8d3a39280388907de90eba9f7fb40c..5f22565fb9268a21bb5e548c9a74c8ed77067d82 100644
--- a/src/mark-compact.cc
+++ b/src/mark-compact.cc
@@ -66,6 +66,7 @@ MarkCompactCollector::MarkCompactCollector() : // NOLINT
marking_parity_(ODD_MARKING_PARITY),
compacting_(false),
was_marked_incrementally_(false),
+ sweeping_pending_(false),
tracer_(NULL),
migration_slots_buffer_(NULL),
heap_(NULL),
@@ -527,7 +528,7 @@ void MarkCompactCollector::ClearMarkbits() {
void MarkCompactCollector::StartSweeperThreads() {
- SweeperThread::set_sweeping_pending(true);
+ sweeping_pending_ = true;
for (int i = 0; i < FLAG_sweeper_threads; i++) {
heap()->isolate()->sweeper_threads()[i]->StartSweeping();
}
@@ -535,11 +536,11 @@ void MarkCompactCollector::StartSweeperThreads() {
void MarkCompactCollector::WaitUntilSweepingCompleted() {
- if (SweeperThread::sweeping_pending()) {
+ if (sweeping_pending_) {
for (int i = 0; i < FLAG_sweeper_threads; i++) {
heap()->isolate()->sweeper_threads()[i]->WaitForSweeperThread();
}
- SweeperThread::set_sweeping_pending(false);
+ sweeping_pending_ = false;
StealMemoryFromSweeperThreads(heap()->paged_space(OLD_DATA_SPACE));
StealMemoryFromSweeperThreads(heap()->paged_space(OLD_POINTER_SPACE));
heap()->FreeQueuedChunks();
@@ -563,7 +564,7 @@ bool MarkCompactCollector::AreSweeperThreadsActivated() {
bool MarkCompactCollector::IsConcurrentSweepingInProgress() {
- return SweeperThread::sweeping_pending();
+ return sweeping_pending_;
}
« no previous file with comments | « src/mark-compact.h ('k') | src/sweeper-thread.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698