Re: [patch] Make slab allocator work with SLAB_MUST_HWCACHE_ALIGN

From: Manfred Spraul
Date: Sat Sep 13 2003 - 15:07:34 EST


Ravikiran G Thirumalai wrote:

I am working on a simplistic allocator for alloc_percpu which
1. Minimises cache footprint (simple pointer arithmetic to get to each cpus version
2. Does numa aware allocation
3. Does not fragment
4. Is simple and extends simple pointer arithmetic to get to cpus offsets

I wouldn't be using the slab at all because using slabs would mean using
NR_CPUs pointers and one extra dereference which is bad as we had found out
earlier. But I guess slab will have to do node local allocations for
other applications.


Interesting. Slab internally uses lots of large per-cpu arrays. Alltogether something like around 40 kB/cpu. Right now implemented with NR_CPUs pointers. In the long run I'll try to switch to your allocator.

But back to the patch that started this thread: Do you still need the ability to set an explicit alignment for slab allocations? If yes, then I'd polish my patch, double check all kmem_cache_create callers and then send the patch to akpm. Otherwise I'd wait - the patch is not a bugfix.

--
Manfred

-
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/