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

Unified Diff: src/mark-compact.cc

Issue 362313002: Precisely sweep scan on scavenge pages and use heap iterator to iterate over them. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 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 | « no previous file | src/store-buffer.cc » ('j') | src/store-buffer.cc » ('J')
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 8846f19bb0dbaeec80192bf9709b3e3f1029cf2c..5ad18a6b3c6a6ea6ee23a1e81e886afa48a4999f 100644
--- a/src/mark-compact.cc
+++ b/src/mark-compact.cc
@@ -4145,12 +4145,23 @@ void MarkCompactCollector::SweepSpace(PagedSpace* space, SweeperType sweeper) {
pages_swept++;
parallel_sweeping_active = true;
} else {
- if (FLAG_gc_verbose) {
- PrintF("Sweeping 0x%" V8PRIxPTR " conservatively in parallel.\n",
- reinterpret_cast<intptr_t>(p));
+ if (p->scan_on_scavenge()) {
+ SweepPrecisely<SWEEP_ONLY, IGNORE_SKIP_LIST, IGNORE_FREE_SPACE>(
+ space, p, NULL);
+ pages_swept++;
+ if (FLAG_gc_verbose) {
+ PrintF("Sweeping 0x%" V8PRIxPTR
+ " scan on scavenge page precisely.\n",
+ reinterpret_cast<intptr_t>(p));
+ }
+ } else {
+ if (FLAG_gc_verbose) {
+ PrintF("Sweeping 0x%" V8PRIxPTR " conservatively in parallel.\n",
+ reinterpret_cast<intptr_t>(p));
+ }
+ p->set_parallel_sweeping(MemoryChunk::PARALLEL_SWEEPING_PENDING);
+ space->IncreaseUnsweptFreeBytes(p);
}
- p->set_parallel_sweeping(MemoryChunk::PARALLEL_SWEEPING_PENDING);
- space->IncreaseUnsweptFreeBytes(p);
}
space->set_end_of_unswept_pages(p);
break;
« no previous file with comments | « no previous file | src/store-buffer.cc » ('j') | src/store-buffer.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698