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

Unified Diff: src/heap/spaces.cc

Issue 463503002: Fix precisely sweeping asserts. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 4 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: src/heap/spaces.cc
diff --git a/src/heap/spaces.cc b/src/heap/spaces.cc
index cfc283f85b7aa628a649cf93c604dddc7fa96359..9be53e03f284018c8b8cafa6462f82712992fba4 100644
--- a/src/heap/spaces.cc
+++ b/src/heap/spaces.cc
@@ -47,7 +47,9 @@ HeapObjectIterator::HeapObjectIterator(Page* page,
owner == page->heap()->code_space());
Initialize(reinterpret_cast<PagedSpace*>(owner), page->area_start(),
page->area_end(), kOnePageOnly, size_func);
- DCHECK(page->WasSweptPrecisely() || page->SweepingCompleted());
+ DCHECK(page->WasSweptPrecisely() ||
+ (static_cast<PagedSpace*>(owner)->swept_precisely() &&
+ page->SweepingCompleted()));
}
@@ -81,7 +83,9 @@ bool HeapObjectIterator::AdvanceToNextPage() {
if (cur_page == space_->anchor()) return false;
cur_addr_ = cur_page->area_start();
cur_end_ = cur_page->area_end();
- DCHECK(cur_page->WasSweptPrecisely());
+ DCHECK(cur_page->WasSweptPrecisely() ||
+ (static_cast<PagedSpace*>(cur_page->owner())->swept_precisely() &&
+ cur_page->SweepingCompleted()));
return true;
}
« 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