Re: [PATCH] irq: better struct irqaction layout

From: Andi Kleen
Date: Thu Nov 04 2010 - 10:35:50 EST


On Thu, Nov 04, 2010 at 11:13:48AM +0100, Eric Dumazet wrote:
> We currently use kmalloc-96 slab for struct irqaction allocations on
> 64bit arches.
>
> This is unfortunate because of possible false sharing and two cache
> lines accesses.
>
> Move 'name' and 'dir' fields at the end of the structure, and force a
> suitable alignement.
>
> Hot path fields now use one cache line on x86_64.

Looks good. It would be nice if some of the fields could be merged (like
thread_flags and flags), but I assume it would be tought to get it back
to 64 bytes again.

Reviewed-by: Andi Kleen <ak@xxxxxxxxxxxxxxx>
-Andi
--
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/