* [PATCH] x86: change the default cache size to 64 bytes
@ 2009-01-12 22:44 Ingo Molnar
2009-01-13 9:24 ` Arjan van de Ven
0 siblings, 1 reply; 2+ messages in thread
From: Ingo Molnar @ 2009-01-12 22:44 UTC (permalink / raw)
To: linux-kernel; +Cc: Thomas Gleixner, H. Peter Anvin, Arjan van de Ven
>From 632c5045d6827a3d044b6eb216d0e5597b25d468 Mon Sep 17 00:00:00 2001
From: Ingo Molnar <mingo@elte.hu>
Date: Mon, 12 Jan 2009 23:37:16 +0100
Subject: [PATCH] x86: change the default cache size to 64 bytes
Right now the generic cacheline size is 128 bytes - that is wasteful
when structures are aligned, as all modern x86 CPUs have an (effective)
cacheline sizes of 64 bytes.
It was set to 128 bytes due to some cacheline aliasing problems on
older P4 systems, but those are many years old and we dont optimize
for them anymore. (They'll still get the 128 bytes cacheline size if
the kernel is specifically built for Pentium 4)
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
arch/x86/Kconfig.cpu | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/x86/Kconfig.cpu b/arch/x86/Kconfig.cpu
index 8078955..cdf4a96 100644
--- a/arch/x86/Kconfig.cpu
+++ b/arch/x86/Kconfig.cpu
@@ -307,10 +307,10 @@ config X86_CMPXCHG
config X86_L1_CACHE_SHIFT
int
- default "7" if MPENTIUM4 || X86_GENERIC || GENERIC_CPU || MPSC
+ default "7" if MPENTIUM4 || MPSC
default "4" if X86_ELAN || M486 || M386 || MGEODEGX1
default "5" if MWINCHIP3D || MWINCHIPC6 || MCRUSOE || MEFFICEON || MCYRIXIII || MK6 || MPENTIUMIII || MPENTIUMII || M686 || M586MMX || M586TSC || M586 || MVIAC3_2 || MGEODE_LX
- default "6" if MK7 || MK8 || MPENTIUMM || MCORE2 || MVIAC7
+ default "6" if MK7 || MK8 || MPENTIUMM || MCORE2 || MVIAC7 || X86_GENERIC || GENERIC_CPU
config X86_XADD
def_bool y
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] x86: change the default cache size to 64 bytes
2009-01-12 22:44 [PATCH] x86: change the default cache size to 64 bytes Ingo Molnar
@ 2009-01-13 9:24 ` Arjan van de Ven
0 siblings, 0 replies; 2+ messages in thread
From: Arjan van de Ven @ 2009-01-13 9:24 UTC (permalink / raw)
To: Ingo Molnar; +Cc: linux-kernel, Thomas Gleixner, H. Peter Anvin
On Mon, 12 Jan 2009 23:44:28 +0100
Ingo Molnar <mingo@elte.hu> wrote:
> >From 632c5045d6827a3d044b6eb216d0e5597b25d468 Mon Sep 17 00:00:00
> >2001
> From: Ingo Molnar <mingo@elte.hu>
> Date: Mon, 12 Jan 2009 23:37:16 +0100
> Subject: [PATCH] x86: change the default cache size to 64 bytes
>
> Right now the generic cacheline size is 128 bytes - that is wasteful
> when structures are aligned, as all modern x86 CPUs have an
> (effective) cacheline sizes of 64 bytes.
>
> It was set to 128 bytes due to some cacheline aliasing problems on
> older P4 systems, but those are many years old and we dont optimize
> for them anymore. (They'll still get the 128 bytes cacheline size if
> the kernel is specifically built for Pentium 4)
>
> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Arjan van de Ven <arjan@linux.intel.com>
--
Arjan van de Ven Intel Open Source Technology Centre
For development, discussion and tips for power savings,
visit http://www.lesswatts.org
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-01-13 9:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-12 22:44 [PATCH] x86: change the default cache size to 64 bytes Ingo Molnar
2009-01-13 9:24 ` Arjan van de Ven
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox