Eset: Cache summary information for heap edatas.

This lets us do a single array scan to find first fits, instead of taking a
cache miss per examined size class.
This commit is contained in:
David Goldblatt
2021-07-20 10:20:44 -07:00
committed by David Goldblatt
parent 252e0942d0
commit dcb7b83fac
2 changed files with 59 additions and 9 deletions

View File

@@ -18,6 +18,14 @@
typedef struct eset_bin_s eset_bin_t;
struct eset_bin_s {
edata_heap_t heap;
/*
* We do first-fit across multiple size classes. If we compared against
* the min element in each heap directly, we'd take a cache miss per
* extent we looked at. If we co-locate the edata summaries, we only
* take a miss on the edata we're actually going to return (which is
* inevitable anyways).
*/
edata_cmp_summary_t heap_min;
};
typedef struct eset_bin_stats_s eset_bin_stats_t;