Re: [PATCH RFC 05/19] slab: add sheaves to most caches
From: Harry Yoo
Date: Sun Oct 26 2025 - 20:25:32 EST
On Thu, Oct 23, 2025 at 03:52:27PM +0200, Vlastimil Babka wrote:
> In the first step to replace cpu (partial) slabs with sheaves, enable
> sheaves for almost all caches. Treat args->sheaf_capacity as a minimum,
> and calculate sheaf capacity with a formula that roughly follows the
> formula for number of objects in cpu partial slabs in set_cpu_partial().
Should we scale sheaf capacity not only based on object size but also
on the number of CPUs, like calculate_order() does?
> This should achieve roughly similar contention on the barn spin lock as
> there's currently for node list_lock without sheaves, to make
> benchmarking results comparable. It can be further tuned later.
>
> Don't enable sheaves for kmalloc caches yet, as that needs further
> changes to bootstraping.
>
> Signed-off-by: Vlastimil Babka <vbabka@xxxxxxx>
> ---
--
Cheers,
Harry / Hyeonggon