Re: [slub p4 6/7] slub: per cpu cache for partial pages

From: Lin Ming
Date: Wed Aug 24 2011 - 03:26:34 EST


On Wed, Aug 10, 2011 at 5:12 AM, Christoph Lameter <cl@xxxxxxxxx> wrote:
> Allow filling out the rest of the kmem_cache_cpu cacheline with pointers to
> partial pages. The partial page list is used in slab_free() to avoid
> per node lock taking.
>
> In __slab_alloc() we can then take multiple partial pages off the per
> node partial list in one go reducing node lock pressure.
>
> We can also use the per cpu partial list in slab_alloc() to avoid scanning
> partial lists for pages with free objects.
>
> The main effect of a per cpu partial list is that the per node list_lock
> is taken for batches of partial pages instead of individual ones.
>
> Potential future enhancements:
>
> 1. The pickup from the partial list could be perhaps be done without disabling
> interrupts with some work. The free path already puts the page into the
> per cpu partial list without disabling interrupts.

Nice patches!

Could you share possible ways for this potential enhancement?

Thanks,
Lin Ming

>
> 2. __slab_free() may have some code paths that could use optimization.


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/