Re: [PATCH] slab: optimize constant-size kzalloc calls
From: Pekka J Enberg
Date: Tue Mar 21 2006 - 06:27:57 EST
Pekka Enberg <penberg@xxxxxxxxxxxxxx> wrote:
> > Please note that the patch
> > increases kernel text slightly (~200 bytes for defconfig on x86)
On Tue, 21 Mar 2006, Andrew Morton wrote:
> Why?
Because of the malloc_sizes lookup. As kindly explained by Eric, we're
now doing:
kzalloc(100, GFP_KERNEL);
and with the patch, we will do:
kmem_cache_zalloc(malloc_sizes[4].cs_dmacachep, GFP_KERNEL);
which explains the the difference. The end result should be faster
kzalloc(), though.
Pekka
-
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/