diff options
author | Qi Wang <interwq@gwu.edu> | 2017-05-22 20:09:17 (GMT) |
---|---|---|
committer | Qi Wang <interwq@gmail.com> | 2017-05-23 20:48:30 (GMT) |
commit | eeefdf3ce89e09ce7cc5c58d2a3730b83045eec1 (patch) | |
tree | 0ccfe2af0f5213284681818e39af4e3b8cd178de /include | |
parent | 0eae838b0d4343b09d80dee00f20a39ce709ca8f (diff) | |
download | jemalloc-eeefdf3ce89e09ce7cc5c58d2a3730b83045eec1.zip jemalloc-eeefdf3ce89e09ce7cc5c58d2a3730b83045eec1.tar.gz jemalloc-eeefdf3ce89e09ce7cc5c58d2a3730b83045eec1.tar.bz2 |
Fix # of unpurged pages in decay algorithm.
When # of dirty pages move below npages_limit (e.g. they are reused), we should
not lower number of unpurged pages because that would cause the reused pages to
be double counted in the backlog (as a result, decay happen slower than it
should). Instead, set number of unpurged to the greater of current npages and
npages_limit.
Added an assertion: the ceiling # of pages should be greater than npages_limit.
Diffstat (limited to 'include')
-rw-r--r-- | include/jemalloc/internal/arena_structs_b.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/jemalloc/internal/arena_structs_b.h b/include/jemalloc/internal/arena_structs_b.h index 459dd89..95680c0 100644 --- a/include/jemalloc/internal/arena_structs_b.h +++ b/include/jemalloc/internal/arena_structs_b.h @@ -103,6 +103,8 @@ struct arena_decay_s { * * Synchronization: Same as associated arena's stats field. */ decay_stats_t *stats; + /* Peak number of pages in associated extents. Used for debug only. */ + uint64_t ceil_npages; }; struct arena_bin_s { |