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

Unified Diff: runtime/vm/freelist.h

Issue 534653002: Bump allocation for promotion (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 3 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
Index: runtime/vm/freelist.h
===================================================================
--- runtime/vm/freelist.h (revision 39806)
+++ runtime/vm/freelist.h (working copy)
@@ -94,7 +94,14 @@
// Returns a large element, at least 'minimum_size', or NULL if none exists.
FreeListElement* TryAllocateLarge(intptr_t minimum_size);
+ FreeListElement* TryAllocateLargeLocked(intptr_t minimum_size);
+ // Allocates locked and unprotected memory, but only from small elements
+ // (i.e., fixed size lists).
+ uword TryAllocateSmall(intptr_t size);
+ // Returns 'b' such that all small elements have size <= 'b' bytes.
+ intptr_t SmallSizeBound() const { return last_free_small_size_; }
+
private:
static const int kNumLists = 128;
@@ -119,6 +126,9 @@
FreeListElement* free_lists_[kNumLists + 1];
+ // The largest available small size in bytes, or negative if there is none.
+ intptr_t last_free_small_size_;
+
DISALLOW_COPY_AND_ASSIGN(FreeList);
};
« no previous file with comments | « runtime/vm/bit_set.h ('k') | runtime/vm/freelist.cc » ('j') | runtime/vm/freelist.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698