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

Unified Diff: src/spaces.h

Issue 3260001: Force relinking of paged space if first attempt to recommit from space fails. (Closed)
Patch Set: Virtualizing block deallocation Created 10 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 | « 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 a6b8ea48df3b7fc17cf4810d9dd0744007c3fe2d..9199cdbb2ada1ccc852c98ffabea05dda9d84c75 100644
--- a/src/spaces.h
+++ b/src/spaces.h
@@ -1039,6 +1039,11 @@ class PagedSpace : public Space {
// Freed pages are moved to the end of page list.
void FreePages(Page* prev, Page* last);
+ // Deallocates a block.
+ virtual void DeallocateBlock(Address start,
+ int size_in_bytes,
+ bool add_to_freelist) = 0;
+
// Set space allocation info.
void SetTop(Address top) {
allocation_info_.top = top;
@@ -1097,6 +1102,8 @@ class PagedSpace : public Space {
// Returns the page of the allocation pointer.
Page* AllocationTopPage() { return TopPageOf(allocation_info_); }
+ void RelinkPageListInChunkOrder(bool deallocate_blocks);
+
protected:
// Maximum capacity of this space.
int max_capacity_;
@@ -1814,6 +1821,10 @@ class OldSpace : public PagedSpace {
}
}
+ virtual void DeallocateBlock(Address start,
+ int size_in_bytes,
+ bool add_to_freelist);
+
// Prepare for full garbage collection. Resets the relocation pointer and
// clears the free list.
virtual void PrepareForMarkCompact(bool will_compact);
@@ -1888,6 +1899,9 @@ class FixedSpace : public PagedSpace {
virtual void PutRestOfCurrentPageOnFreeList(Page* current_page);
+ virtual void DeallocateBlock(Address start,
+ int size_in_bytes,
+ bool add_to_freelist);
#ifdef DEBUG
// Reports statistic info of the space
void ReportStatistics();
« 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