|Title||Hysteresis overwhelmed by allocation|
|Assigned user||Richard Brooksby|
|Description||Profiling "djbench mvt" on Mac OS X shows 5% of time is spent in mmap/munmap, even though djbench is just churning allocation rapidly. Increasing ARENA_INIT_SPARE_COMMIT_LIMIT in config.h from 10MiB to 100MiB cures this.|
|Analysis||The VM arena implements some hysteresis on VMMap by retaining "spare" (free but mapped) pages. The MPS implements a tuning interface for this with mps_arena_spare_commit_limit_set() but it's in terms of a fixed size, as is the default, currently 10MiB. This doesn't scale.|
The hysteresis should be expressed as a proportion or overhead, so that it can scale up with MPS memory usage. In addition, it's possible that there ought to be more hysteresis when pages are being turned over rapidly, perhaps by having some kind of half-life on the spare pages, so that periods of rapid churn don't overwhelm even that.
GDR 2014-02-03: this was previously reported as job003371.
GDR 2014-03-17: see also job003700.
|Evidence||See description for repro.|
|Created by||Richard Brooksby|
|Created on||2014-01-31 12:53:24|
|Last modified by||Gareth Rees|
|Last modified on||2018-08-13 13:55:48|
|History||2014-01-31 RB Created.|
2014-02-03 GDR Cross-reference job003371.
2014-03-17 GDR Cross-reference job003700.
|194962||closed||2018-08-13 13:55:47||Gareth Rees||Merge branch/2016-03-04/spare-fraction into the master sources.|
|184359||open||2014-02-17 17:05:37||Richard Brooksby||Merging spare-ring branch into master, from //info.ravenbrook.com/project/mps/branch/2014-01-25/spare-ring/...|