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

Unified Diff: runtime/vm/pages.h

Issue 10458072: Force growth when retrying an old-space allocation. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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
« no previous file with comments | « runtime/vm/heap.cc ('k') | runtime/vm/pages.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/pages.h
diff --git a/runtime/vm/pages.h b/runtime/vm/pages.h
index afe418ab102f9bf00f2317a53f464c65736fd764..1d595458c1924e5b78ce7baca7df3ff2990bce5a 100644
--- a/runtime/vm/pages.h
+++ b/runtime/vm/pages.h
@@ -151,10 +151,16 @@ class PageSpace {
static const intptr_t kPageSize = 256 * KB;
static const intptr_t kPageAlignment = kPageSize;
+ enum GrowthPolicy {
+ kControlGrowth,
+ kForceGrowth
+ };
+
PageSpace(Heap* heap, intptr_t max_capacity, bool is_executable = false);
~PageSpace();
uword TryAllocate(intptr_t size);
+ uword TryAllocate(intptr_t size, GrowthPolicy growth_policy);
intptr_t in_use() const { return in_use_; }
intptr_t capacity() const { return capacity_; }
« no previous file with comments | « runtime/vm/heap.cc ('k') | runtime/vm/pages.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698