[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Mon, 3 Mar 2008 13:23:48 -0800 (PST)
From: Christoph Lameter <clameter@....com>
To: Pekka Enberg <penberg@...helsinki.fi>
cc: Nick Piggin <npiggin@...e.de>, netdev@...r.kernel.org,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
yanmin_zhang@...ux.intel.com, David Miller <davem@...emloft.net>,
Eric Dumazet <dada1@...mosbay.com>
Subject: Re: [rfc][patch 2/3] slab: introduce SMP alignment
On Mon, 3 Mar 2008, Pekka Enberg wrote:
> Hmm... Can't we just fix SLAB_HWCACHE_ALIGN in SLUB to follow the
> semantics of SLAB?
AFAICT it follows SLAB semantics. The only small difference is for objects
small than cache_line_size() / 2 where SLUB does not bother to align to a
fraction of a cacheline since we are already placing multile object into a
cacheline. We effectively have made the decision to give up the
organization of objects in separatate cache lines.
Lets say you have a 64 byte cache line size. Then the alignment can be
as follows. (8 byte alignment is the basic alignment requirement).
Objsize [C SLAB SLUB
-----------------------------
> 64 X X
33 .. 64 64 64
32 32 32
24 32 24 -> 3 object per cacheline sizes = 72 so overlap.
16 16 16
8 8 8
So there is only one difference for 24 byte sizes slabs.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists