On Tue, 11 Aug 2026 12:35:41 +0000
Morten Brørup <[email protected]> wrote:

> Early submission of:
> - A new "pile" stack-like implementation using the Stack API, and
> - an accompanying "pile" mempool driver.
> 
> For CI test and community feedback.
> 
> Needless to say, this must be separated into multiple independent
> series of patches.
> And release notes must be added.
> For now, I'm submitting a snapshot of work in progress.
> 
> The "pile" somewhat resembles the lock-free stack, but operates on
> bulks (arrays) of objects, to significantly reduce linked list
> traversal.
> With the pile's default bulk size of 32 objects, a mempool cache
> flush/refill traverses a linked list of only 16 elements, whereas
> the lock-free stack would traverse a linked list of 512 elements.
> 
> Some performance numbers from mempool_perf_autotest_2cores, all
> with cache=1024 cores=2 n_keep=32768:
> 
> start performance test (using ring_mp_mc, with cache)
> n_get_bulk= 64 n_put_bulk= 64 constant_n=0 rate_persec= 753985338
> n_get_bulk=256 n_put_bulk=256 constant_n=0 rate_persec= 755805913
> 
> start performance test for lf_stack (with cache)
> n_get_bulk= 64 n_put_bulk= 64 constant_n=0 rate_persec=  29132352
> n_get_bulk=256 n_put_bulk=256 constant_n=0 rate_persec=  29276708
> 
> start performance test for pile (with cache)
> n_get_bulk= 64 n_put_bulk= 64 constant_n=0 rate_persec= 560159479
> n_get_bulk=256 n_put_bulk=256 constant_n=0 rate_persec= 557910933
> 
> Hat tip to Bruce for bringing attention to the ring not being the
> optimal mempool driver!
> 
> Note: The GitHub "mini" tests don't include the "pile" mempool driver,
> and are expected to fail.
> 
> Signed-off-by: Morten Brørup <[email protected]>

Right but the 32 bit code fails at run time.

 MEMPOOL: Cache size 250 not divisible by 32, rounding down to 224.
STACK: rte_stack_create(): Pile is not supported on your platform

Should be possible to correct this at compile. Like if pile is not
available on this platform, something else should be the default.

The CI failures indicate places where it is likely to be a problem
for users.

Reply via email to