Re: [PATCH 1/3] x86-64: Convert the PDA to percpu.

From: Ingo Molnar
Date: Sat Dec 27 2008 - 05:41:53 EST



(Cc:-ed a few more people who might be interested in this)

* Brian Gerst <brgerst@xxxxxxxxx> wrote:

> This patch makes the PDA a normal per-cpu variable, allowing the
> removal of the special allocator code. %gs still points to the
> base of the PDA.
>
> Tested on a dual-core AMD64 system.
>
> Signed-off-by: Brian Gerst <brgerst@xxxxxxxxx>
> ---
> arch/x86/include/asm/pda.h | 3 --
> arch/x86/include/asm/percpu.h | 3 --
> arch/x86/include/asm/setup.h | 1 -
> arch/x86/kernel/cpu/common.c | 6 ++--
> arch/x86/kernel/dumpstack_64.c | 8 ++--
> arch/x86/kernel/head64.c | 23 +------------
> arch/x86/kernel/irq.c | 2 +-
> arch/x86/kernel/nmi.c | 2 +-
> arch/x86/kernel/setup_percpu.c | 70 ++++++++--------------------------------
> arch/x86/kernel/smpboot.c | 58 +--------------------------------
> arch/x86/xen/enlighten.c | 2 +-
> arch/x86/xen/smp.c | 12 +------
> 12 files changed, 27 insertions(+), 163 deletions(-)

the simplification factor is significant. I'm wondering, have you measured
the code size impact of this on say the defconfig x86 kernel? That will
generally tell us how much worse optimizations the compiler does under
this scheme.

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