From 83150861e610701d44510816e2062bcf407f51ab Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Tue, 29 Mar 2011 22:38:53 -0700 Subject: [PATCH] Decrease target objects per slab By decreasing the number of target objects per slab we increase the likelyhood that a slab can be freed. This reduces the level of fragmentation in the slab which has been observed to be a problem for certain workloads. The penalty for this is that we also decrease the speed which need objects can be allocated. --- include/sys/kmem.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/sys/kmem.h b/include/sys/kmem.h index d3972f1ca7..72f70c2820 100644 --- a/include/sys/kmem.h +++ b/include/sys/kmem.h @@ -334,7 +334,7 @@ extern struct rw_semaphore spl_kmem_cache_sem; #define SPL_KMEM_CACHE_DELAY 15 /* Minimum slab release age */ #define SPL_KMEM_CACHE_REAP 0 /* Default reap everything */ -#define SPL_KMEM_CACHE_OBJ_PER_SLAB 32 /* Target objects per slab */ +#define SPL_KMEM_CACHE_OBJ_PER_SLAB 16 /* Target objects per slab */ #define SPL_KMEM_CACHE_OBJ_PER_SLAB_MIN 8 /* Minimum objects per slab */ #define SPL_KMEM_CACHE_ALIGN 8 /* Default object alignment */