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

Unified Diff: src/spaces.h

Issue 12529005: Ignore evacuation canditate pages when verifying spaces. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 9 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.cc ('k') | src/spaces.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/spaces.h
diff --git a/src/spaces.h b/src/spaces.h
index 6ff3ee3694dccd769a61bbc35342b66a317342f7..a19dfd284491dfd52cd2a3f1006f92940c37ef34 100644
--- a/src/spaces.h
+++ b/src/spaces.h
@@ -1206,6 +1206,20 @@ class HeapObjectIterator: public ObjectIterator {
return NULL;
}
+ // Advance to the next object, skipping free spaces, evacuation canditates,
+ // and other fillers and skipping the special garbage section of which
+ // there is one per space. Returns NULL when the iteration has ended.
+ inline HeapObject* NextIgnoreEvacuationCandidates() {
+ do {
+ if (cur_addr_ != 0 &&
+ !Page::FromAddress(cur_addr_ - 1)->IsEvacuationCandidate()) {
+ HeapObject* next_obj = FromCurrentPage();
+ if (next_obj != NULL) return next_obj;
+ }
+ } while (AdvanceToNextPage());
+ return NULL;
+ }
+
virtual HeapObject* next_object() {
return Next();
}
« no previous file with comments | « src/mark-compact.cc ('k') | src/spaces.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698