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

Unified Diff: src/spaces-inl.h

Issue 7000023: Do inline object filtering (via page flags) before call to RecordWriteStub. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/gc
Patch Set: Created 9 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
« src/spaces.h ('K') | « src/spaces.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/spaces-inl.h
diff --git a/src/spaces-inl.h b/src/spaces-inl.h
index bcb6e63ad70af630d4e77e34c806fb3f8754dcdb..31e0cbee9f1bef887a123df3d5bea323c45387da 100644
--- a/src/spaces-inl.h
+++ b/src/spaces-inl.h
@@ -127,6 +127,9 @@ Page* Page::Initialize(Heap* heap,
owner->IncreaseCapacity(Page::kObjectAreaSize);
owner->Free(page->ObjectAreaStart(),
page->ObjectAreaEnd() - page->ObjectAreaStart());
+
+ heap->incremental_marking()->SetOldSpacePageFlags(chunk);
+
return page;
}
@@ -140,11 +143,13 @@ bool PagedSpace::Contains(Address addr) {
void MemoryChunk::set_scan_on_scavenge(bool scan) {
if (scan) {
- if (!scan_on_scavenge_) heap_->increment_scan_on_scavenge_pages();
+ if (!scan_on_scavenge()) heap_->increment_scan_on_scavenge_pages();
+ SetFlag(SCAN_ON_SCAVENGE);
} else {
- if (scan_on_scavenge_) heap_->decrement_scan_on_scavenge_pages();
+ if (scan_on_scavenge()) heap_->decrement_scan_on_scavenge_pages();
+ ClearFlag(SCAN_ON_SCAVENGE);
}
- scan_on_scavenge_ = scan;
+ heap_->incremental_marking()->SetOldSpacePageFlags(this);
}
@@ -269,6 +274,13 @@ MaybeObject* NewSpace::AllocateRawInternal(int size_in_bytes) {
}
+LargePage* LargePage::Initialize(Heap* heap, MemoryChunk* chunk) {
+ // TODO(gc) ISOLATESMERGE initialize chunk to point to heap?
Erik Corry 2011/05/11 18:53:57 I don't see how we can defer this to a TODO. We h
Vyacheslav Egorov (Chromium) 2011/05/13 11:06:52 Done.
+ heap->incremental_marking()->SetOldSpacePageFlags(chunk);
+ return static_cast<LargePage*>(chunk);
+}
+
+
intptr_t LargeObjectSpace::Available() {
return ObjectSizeFor(heap()->isolate()->memory_allocator()->Available());
}
« src/spaces.h ('K') | « src/spaces.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698