* Re: [RFC][2.5 patch] K6-II/K6-II: enable X86_USE_3DNOW
2003-04-14 22:27 ` Dave Jones
@ 2003-04-14 22:06 ` Alan Cox
2003-04-15 19:37 ` Adrian Bunk
0 siblings, 1 reply; 7+ messages in thread
From: Alan Cox @ 2003-04-14 22:06 UTC (permalink / raw)
To: Dave Jones; +Cc: Adrian Bunk, Linux Kernel Mailing List
On Llu, 2003-04-14 at 23:27, Dave Jones wrote:
> On Tue, Apr 15, 2003 at 12:21:10AM +0200, Adrian Bunk wrote:
> > If my patch is wrong and this is a RTFM please give me a hint where to
> > find the "M".
> >
> > The AMD K6-II and K6-III do support 3DNow!
>
> The 3dnow memory copies aren't a win on anything
> earlier than an Athlon iirc.
Under 1% on a K6. The processor is so horribly memory bound the
actual copy function is borderline irrelevant. If its not in the
K6-III cache its not arriving in a hurry
^ permalink raw reply [flat|nested] 7+ messages in thread
* [RFC][2.5 patch] K6-II/K6-II: enable X86_USE_3DNOW
@ 2003-04-14 22:21 Adrian Bunk
2003-04-14 22:27 ` Dave Jones
2003-04-14 22:36 ` Robert Love
0 siblings, 2 replies; 7+ messages in thread
From: Adrian Bunk @ 2003-04-14 22:21 UTC (permalink / raw)
To: linux-kernel
If my patch is wrong and this is a RTFM please give me a hint where to
find the "M".
The AMD K6-II and K6-III do support 3DNow!
The patch below adds a new option for the AMD K6-II and K6-III and
enables CONFIG_X86_USE_3DNOW.
I'm currently running 2.5.67 with this patch applied on my K6-II.
Questions:
Is it really correct to enable CONFIG_X86_USE_3DNOW?
Is the -march=k6-2 correct?
TIA
Adrian
--- linux-2.5.67/arch/i386/Kconfig.old 2003-04-14 22:17:56.000000000 +0200
+++ linux-2.5.67/arch/i386/Kconfig 2003-04-14 22:21:07.000000000 +0200
@@ -128,7 +128,8 @@
- "Pentium-II" for the Intel Pentium II or pre-Coppermine Celeron.
- "Pentium-III" for the Intel Pentium III or Coppermine Celeron.
- "Pentium-4" for the Intel Pentium 4 or P4-based Celeron.
- - "K6" for the AMD K6, K6-II and K6-III (aka K6-3D).
+ - "K6" for the AMD K6.
+ - "K6_2" for the AMD K6-II and K6-III (aka K6-3D).
- "Athlon" for the AMD K7 family (Athlon/Duron/Thunderbird).
- "Crusoe" for the Transmeta Crusoe series.
- "Winchip-C6" for original IDT Winchip.
@@ -200,12 +201,19 @@
optimizations.
config MK6
- bool "K6/K6-II/K6-III"
+ bool "K6"
help
- Select this for an AMD K6-family processor. Enables use of
- some extended instructions, and passes appropriate optimization
+ Select this for an AMD K6 processor. Enables use of some
+ extended instructions, and passes appropriate optimization
flags to GCC.
+config MK6_2
+ bool "K6-II/K6-III"
+ help
+ Select this for an AMD K6-II and K6-III processors. Enables
+ use of some extended instructions, and passes appropriate
+ optimization flags to GCC.
+
config MK7
bool "Athlon/Duron/K7"
help
@@ -289,7 +297,7 @@
config X86_L1_CACHE_SHIFT
int
default "4" if MELAN || M486 || M386
- default "5" if MWINCHIP3D || MWINCHIP2 || MWINCHIPC6 || MCRUSOE || MCYRIXIII || MK6 || MPENTIUMIII || MPENTIUMII || M686 || M586MMX || M586TSC || M586 || MVIAC3_2
+ default "5" if MWINCHIP3D || MWINCHIP2 || MWINCHIPC6 || MCRUSOE || MCYRIXIII || MK6 || MK6_2 || MPENTIUMIII || MPENTIUMII || M686 || M586MMX || M586TSC || M586 || MVIAC3_2
default "6" if MK7 || MK8
default "7" if MPENTIUM4
@@ -335,7 +343,7 @@
config X86_ALIGNMENT_16
bool
- depends on MWINCHIP3D || MWINCHIP2 || MWINCHIPC6 || MCYRIXIII || MELAN || MK6 || M586MMX || M586TSC || M586 || M486 || MVIAC3_2
+ depends on MWINCHIP3D || MWINCHIP2 || MWINCHIPC6 || MCYRIXIII || MELAN || MK6 || MK6_2 || M586MMX || M586TSC || M586 || M486 || MVIAC3_2
default y
config X86_GOOD_APIC
@@ -350,12 +358,12 @@
config X86_USE_PPRO_CHECKSUM
bool
- depends on MWINCHIP3D || MWINCHIP2 || MWINCHIPC6 || MCYRIXIII || MK7 || MK6 || MPENTIUM4 || MPENTIUMIII || MPENTIUMII || M686 || MK8 || MVIAC3_2
+ depends on MWINCHIP3D || MWINCHIP2 || MWINCHIPC6 || MCYRIXIII || MK7 || MK6 || MK6_2 || MPENTIUM4 || MPENTIUMIII || MPENTIUMII || M686 || MK8 || MVIAC3_2
default y
config X86_USE_3DNOW
bool
- depends on MCYRIXIII || MK7
+ depends on MCYRIXIII || MK6_2 || MK7
default y
config X86_OOSTORE
@@ -478,7 +486,7 @@
config X86_TSC
bool
- depends on (MWINCHIP3D || MWINCHIP2 || MCRUSOE || MCYRIXIII || MK7 || MK6 || MPENTIUM4 || MPENTIUMIII || MPENTIUMII || M686 || M586MMX || M586TSC || MK8 || MVIAC3_2) && !X86_NUMAQ
+ depends on (MWINCHIP3D || MWINCHIP2 || MCRUSOE || MCYRIXIII || MK7 || MK6 || MK6_2 || MPENTIUM4 || MPENTIUMIII || MPENTIUMII || M686 || M586MMX || M586TSC || MK8 || MVIAC3_2) && !X86_NUMAQ
default y
config X86_MCE
--- linux-2.5.67/arch/i386/Makefile.old 2003-04-14 22:23:34.000000000 +0200
+++ linux-2.5.67/arch/i386/Makefile 2003-04-14 22:25:01.000000000 +0200
@@ -39,6 +39,7 @@
cflags-$(CONFIG_MPENTIUMIII) += $(call check_gcc,-march=pentium3,-march=i686)
cflags-$(CONFIG_MPENTIUM4) += $(call check_gcc,-march=pentium4,-march=i686)
cflags-$(CONFIG_MK6) += $(call check_gcc,-march=k6,-march=i586)
+cflags-$(CONFIG_MK6_2) += $(call check_gcc,-march=k6-2,-march=i586)
cflags-$(CONFIG_MK7) += $(call check_gcc,-march=athlon,-march=i686 $(align)-functions=4)
cflags-$(CONFIG_MK8) += $(call check_gcc,-march=k8,$(call check_gcc,-march=athlon,-march=i686 $(align)-functions=4))
cflags-$(CONFIG_MCRUSOE) += -march=i686 $(align)-functions=0 $(align)-jumps=0 $(align)-loops=0
--- linux-2.5.67/include/asm-i386/module.h.old 2003-04-14 22:25:59.000000000 +0200
+++ linux-2.5.67/include/asm-i386/module.h 2003-04-14 22:26:34.000000000 +0200
@@ -30,6 +30,8 @@
#define MODULE_PROC_FAMILY "PENTIUM4 "
#elif defined CONFIG_MK6
#define MODULE_PROC_FAMILY "K6 "
+#elif defined CONFIG_MK6_2
+#define MODULE_PROC_FAMILY "K6II "
#elif defined CONFIG_MK7
#define MODULE_PROC_FAMILY "K7 "
#elif defined CONFIG_MK8
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [RFC][2.5 patch] K6-II/K6-II: enable X86_USE_3DNOW
2003-04-14 22:21 [RFC][2.5 patch] K6-II/K6-II: enable X86_USE_3DNOW Adrian Bunk
@ 2003-04-14 22:27 ` Dave Jones
2003-04-14 22:06 ` Alan Cox
2003-04-14 22:36 ` Robert Love
1 sibling, 1 reply; 7+ messages in thread
From: Dave Jones @ 2003-04-14 22:27 UTC (permalink / raw)
To: Adrian Bunk; +Cc: linux-kernel
On Tue, Apr 15, 2003 at 12:21:10AM +0200, Adrian Bunk wrote:
> If my patch is wrong and this is a RTFM please give me a hint where to
> find the "M".
>
> The AMD K6-II and K6-III do support 3DNow!
The 3dnow memory copies aren't a win on anything
earlier than an Athlon iirc.
Dave
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [RFC][2.5 patch] K6-II/K6-II: enable X86_USE_3DNOW
2003-04-14 22:21 [RFC][2.5 patch] K6-II/K6-II: enable X86_USE_3DNOW Adrian Bunk
2003-04-14 22:27 ` Dave Jones
@ 2003-04-14 22:36 ` Robert Love
2003-04-15 8:50 ` Paweł Gołaszewski
2003-04-15 19:39 ` Adrian Bunk
1 sibling, 2 replies; 7+ messages in thread
From: Robert Love @ 2003-04-14 22:36 UTC (permalink / raw)
To: Adrian Bunk; +Cc: linux-kernel
On Mon, 2003-04-14 at 18:21, Adrian Bunk wrote:
> If my patch is wrong and this is a RTFM please give me a hint where to
> find the "M".
Patch looks right...
> Questions:
> Is it really correct to enable CONFIG_X86_USE_3DNOW?
If you are right that the K6-2 and K6-3D support 3DNow!, then yes. At
least its "correct" but it may not be optimal: I seem to recall 3DNow
memory copies were not worthwhile on anything before an Athlon. Double
check that, though.
> Is the -march=k6-2 correct?
Yes. Even if the above is true, splitting the K6 out like this is
useful for the extra -march here. It certainly does not hurt (picking
the original K6 will give proper support for the whole family, in
needed).
Robert Love
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [RFC][2.5 patch] K6-II/K6-II: enable X86_USE_3DNOW
2003-04-14 22:36 ` Robert Love
@ 2003-04-15 8:50 ` Paweł Gołaszewski
2003-04-15 19:39 ` Adrian Bunk
1 sibling, 0 replies; 7+ messages in thread
From: Paweł Gołaszewski @ 2003-04-15 8:50 UTC (permalink / raw)
To: Robert Love; +Cc: Adrian Bunk, linux-kernel
On Tue, 14 Apr 2003, Robert Love wrote:
> > Questions: Is it really correct to enable CONFIG_X86_USE_3DNOW?
> If you are right that the K6-2 and K6-3D support 3DNow!, then yes.
Yes, it does.
--
pozdr. Paweł Gołaszewski
---------------------------------
worth to see: http://www.againsttcpa.com/
CPU not found - software emulation...
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [RFC][2.5 patch] K6-II/K6-II: enable X86_USE_3DNOW
2003-04-14 22:06 ` Alan Cox
@ 2003-04-15 19:37 ` Adrian Bunk
0 siblings, 0 replies; 7+ messages in thread
From: Adrian Bunk @ 2003-04-15 19:37 UTC (permalink / raw)
To: Alan Cox; +Cc: Dave Jones, Linux Kernel Mailing List
On Mon, Apr 14, 2003 at 11:06:28PM +0100, Alan Cox wrote:
> On Llu, 2003-04-14 at 23:27, Dave Jones wrote:
> > On Tue, Apr 15, 2003 at 12:21:10AM +0200, Adrian Bunk wrote:
> > > If my patch is wrong and this is a RTFM please give me a hint where to
> > > find the "M".
> > >
> > > The AMD K6-II and K6-III do support 3DNow!
> >
> > The 3dnow memory copies aren't a win on anything
> > earlier than an Athlon iirc.
>
> Under 1% on a K6. The processor is so horribly memory bound the
> actual copy function is borderline irrelevant. If its not in the
> K6-III cache its not arriving in a hurry
Ah thanks, this is the information I didn't know.
cu
Adrian
--
"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [RFC][2.5 patch] K6-II/K6-II: enable X86_USE_3DNOW
2003-04-14 22:36 ` Robert Love
2003-04-15 8:50 ` Paweł Gołaszewski
@ 2003-04-15 19:39 ` Adrian Bunk
1 sibling, 0 replies; 7+ messages in thread
From: Adrian Bunk @ 2003-04-15 19:39 UTC (permalink / raw)
To: Robert Love; +Cc: linux-kernel
On Mon, Apr 14, 2003 at 06:36:20PM -0400, Robert Love wrote:
> On Mon, 2003-04-14 at 18:21, Adrian Bunk wrote:
>
> > If my patch is wrong and this is a RTFM please give me a hint where to
> > find the "M".
>
> Patch looks right...
>
> > Questions:
> > Is it really correct to enable CONFIG_X86_USE_3DNOW?
>
> If you are right that the K6-2 and K6-3D support 3DNow!, then yes. At
> least its "correct" but it may not be optimal: I seem to recall 3DNow
> memory copies were not worthwhile on anything before an Athlon. Double
> check that, though.
It does, but Alan already explained why it doesn't make a difference.
> > Is the -march=k6-2 correct?
>
> Yes. Even if the above is true, splitting the K6 out like this is
> useful for the extra -march here. It certainly does not hurt (picking
> the original K6 will give proper support for the whole family, in
> needed).
>From a quick look of the gcc-3.2.2 sources it seems that except for the
3DNow! support gcc doesn't differenciate between K6 and K6-II, so this
change alone doesn't seem to make it worth adding a new processor type.
> Robert Love
cu
Adrian
--
"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2003-04-15 19:27 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-04-14 22:21 [RFC][2.5 patch] K6-II/K6-II: enable X86_USE_3DNOW Adrian Bunk
2003-04-14 22:27 ` Dave Jones
2003-04-14 22:06 ` Alan Cox
2003-04-15 19:37 ` Adrian Bunk
2003-04-14 22:36 ` Robert Love
2003-04-15 8:50 ` Paweł Gołaszewski
2003-04-15 19:39 ` Adrian Bunk
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox