x86: Fix incorrect __read_mostly on _boot_cpu_pda
PATCH 1/1 x86: Fix incorrect __read_mostly on _boot_cpu_pda
The pda rework (commit 3461b0af025251bbc6b3d56c821c6ac2de6f7209) to remove static boot cpu pdas introduced a bug. _boot_cpu_pda is the actual pda used by the boot cpu and is definitely not "__read_mostly" and ended up polluting the read mostly section with writes. This bug caused regression of about 8-10% on certain syscall intensive workloads.
arch/x86/kernel/head64.c +1 -1
@@ -27,7 +27,7 @@#include <asm/trampoline.h> /* boot cpu pda */ -static struct x8664_pda _boot_cpu_pda__read_mostly ; +static struct x8664_pda _boot_cpu_pda;#ifdef CONFIG_SMP /*
Quoted 13 lines · Ravikiran G Thirumalai
The pda rework (commit
3461b0af025251bbc6b3d56c821c6ac2de6f7209) to remove static boot cpu pdas introduced a bug._boot_cpu_pdais the actual pda used by the boot cpu and is definitely not "__read_mostly" and ended up polluting the read mostly section with writes. This bug caused regression of about 8-10% on certain syscall intensive workloads.Signed-off-by Ravikiran Thirumalai <[email protected]>Index:
linux-2.6/arch/x86/kernel/head64.c
===================================================================
arch/x86/kernel/head64.c line 33
Quoted 8 lines
arch/x86/kernel/head64.c +1
-1@@ -27,7 +27,7 @@#include <asm/trampoline.h> /* boot cpu pda */ -static struct x8664_pda _boot_cpu_pda__read_mostly ; +static struct x8664_pda _boot_cpu_pda;#ifdef CONFIG_SMP /*
Thanks for catching that!
Mike
Ingo Molnar
AppliedQuoted 7 lines · Ravikiran G Thirumalai
The pda rework (commit
3461b0af025251bbc6b3d56c821c6ac2de6f7209) to remove static boot cpu pdas introduced a bug._boot_cpu_pdais the actual pda used by the boot cpu and is definitely not "__read_mostly" and ended up polluting the read mostly section with writes. This bug caused regression of about 8-10% on certain syscall intensive workloads.Signed-off-by Ravikiran Thirumalai <[email protected]>
applied to tip/x86/urgent, with a Cc: stable tag. Thanks,
Ingo
Ravikiran G Thirumalai
Acked-by Mike TravisQuoted 9 lines · Ingo Molnar
Quoted 6 lines · Ravikiran G Thirumalai
The pda rework (commit
3461b0af025251bbc6b3d56c821c6ac2de6f7209) to remove static boot cpu pdas introduced a bug._boot_cpu_pdais the actual pda used by the boot cpu and is definitely not "__read_mostly" and ended up polluting the read mostly section with writes. This bug caused regression of about 8-10% on certain syscall intensive workloads.
Quoted 4 lines
Quoted 1 line
Signed-off-by Ravikiran Thirumalai <[email protected]>applied to tip/x86/urgent, with a Cc: stable tag. Thanks,
Thanks!
Stable maintainers, please consider this for 2.6.27 stable as well (in addition to 28). (Attaching the tip/x86/urgent commit as reference to the patch)
Thanks,
Kiran
commit 26799a63110dcbe81291ea53178f6b4810d07424
Author: Ravikiran G Thirumalai <[email protected]> Date: Wed Dec 31 13:44:46 2008 -0800
x86: fix incorrect __read_mostly on _boot_cpu_pda
The pda rework (commit 3461b0af025251bbc6b3d56c821c6ac2de6f7209) to remove static boot cpu pdas introduced a performance bug.
_boot_cpu_pda is the actual pda used by the boot cpu and is definitely not "__read_mostly" and ended up polluting the read mostly section with writes. This bug caused regression of about 8-10% on certain syscall intensive workloads.
arch/x86/kernel/head64.c +1 -1
@@ -27,7 +27,7 @@#include <asm/trampoline.h> /* boot cpu pda */ -static struct x8664_pda _boot_cpu_pda__read_mostly ; +static struct x8664_pda _boot_cpu_pda;#ifdef CONFIG_SMP /*
Quoted 12 lines · Ravikiran G Thirumalai
Quoted 11 lines · Ingo Molnar
Quoted 7 lines · Ravikiran G Thirumalai
The pda rework (commit
3461b0af025251bbc6b3d56c821c6ac2de6f7209) to remove static boot cpu pdas introduced a bug._boot_cpu_pdais the actual pda used by the boot cpu and is definitely not "__read_mostly" and ended up polluting the read mostly section with writes. This bug caused regression of about 8-10% on certain syscall intensive workloads.Signed-off-by Ravikiran Thirumalai <[email protected]>
Quoted 8 lines
Quoted 2 lines
applied to tip/x86/urgent, with a Cc: stable tag. Thanks,
Thanks!
Stable maintainers, please consider this for 2.6.27 stable as well (in addition to 28). (Attaching the tip/x86/urgent commit as reference to the patch)
i have added a -stable tag to the commit - please only put it into -stable once it hits Linus's tree. (in the next couple of days)
Quoted 1 line
Ingo