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

Unified Diff: src/spaces.h

Issue 414045: After performing scavenge, hint OS that data in from spaces are no more neede... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 1 month 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/platform-win32.cc ('k') | src/spaces-inl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/spaces.h
===================================================================
--- src/spaces.h (revision 3342)
+++ src/spaces.h (working copy)
@@ -440,6 +440,11 @@
// and false otherwise.
static bool UncommitBlock(Address start, size_t size);
+ // Give OS a hint that data of this contiguous block of memory are no longer
+ // needed and could be discarded. This does NOT uncommit the block though.
+ static inline bool ResetBlock(Address start, size_t size,
+ Executability executable);
+
// Attempts to allocate the requested (non-zero) number of pages from the
// OS. Fewer pages might be allocated than requested. If it fails to
// allocate memory for the OS or cannot allocate a single page, this
@@ -1130,6 +1135,7 @@
bool is_committed() { return committed_; }
bool Commit();
bool Uncommit();
+ inline bool Reset();
#ifdef DEBUG
virtual void Print();
@@ -1389,6 +1395,10 @@
return from_space_.Uncommit();
}
+ bool ResetFromSpace() {
+ return from_space_.Reset();
+ }
+
private:
// The semispaces.
SemiSpace to_space_;
« no previous file with comments | « src/platform-win32.cc ('k') | src/spaces-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698