Re: [patch]K6-2/K-III compile option

Anders Fugmann (afu@bording.dk)
Thu, 30 Sep 1999 12:19:26 +0200


This is a multi-part message in MIME format.
--------------9402817FF82E473993AD83AD
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Oops.
It seems that a small error sneeked in.
Here is the correct patch:

Anders Fugmann

***Patch begins***

diff -r -u vanilla-2.3.18ac10/Documentation/Configure.help
linux/Documentation/Configure.help
--- vanilla-2.3.18ac10/Documentation/Configure.help Thu Sep 30
10:58:59 1999
+++ linux/Documentation/Configure.help Thu Sep 30 11:04:29 1999
@@ -1849,10 +1849,10 @@
all x86 CPU types (albeit not optimally fast), you can specify
"386" here.

- If you specify one of "486" or "586" or "Pentium" or "PPro", then
- the kernel will not necessarily run on earlier architectures (e.g. a
- Pentium optimized kernel will run on a PPro, but not necessarily on
- a i486).
+ If you specify one of "486" or "586" or "Pentium" or "K6" or "PPro"
or
+ K7, then the kernel will not necessarily run on earlier architectures
+ (e.g. a Pentium optimized kernel will run on a PPro, but not
necessarily
+ on a i486).

Here are the settings recommended for greatest speed:
- "386" for the AMD/Cyrix/Intel 386DX/DXL/SL/SLC/SX, Cyrix/TI
@@ -1862,10 +1862,11 @@
AMD/Cyrix 5x86, NexGen Nx586 and UMC U5D or U5S.
- "586" for generic Pentium CPUs, possibly lacking the TSC
(time stamp counter) register.
- - "Pentium" for the Intel Pentium/Pentium MMX, AMD K5, K6 and
- K6-3D.
+ - "Pentium" for the Intel Pentium/Pentium MMX, AMD K5 and K6
+ - "K6-II(I)" for AMD K6-2 or AMD K6-III
- "PPro" for the Cyrix/IBM/National Semiconductor 6x86MX, MII and
Intel Pentium II/Pentium Pro.
+ - "K7" for the AMD Atlon processor.

If you don't know what to do, choose "386".

diff -r -u vanilla-2.3.18ac10/arch/i386/Makefile
linux/arch/i386/Makefile
--- vanilla-2.3.18ac10/arch/i386/Makefile Thu Sep 30 10:58:59 1999
+++ linux/arch/i386/Makefile Wed Sep 29 19:07:24 1999
@@ -52,6 +52,12 @@
AFLAGS := $(AFLAGS) -DCPU=586
endif

+ifdef CONFIG_MK6
+CFLAGS := $(CFLAGS) -DCPU=586
+CFLAGS += $(shell if $(CC) -march=k6 -S -o /dev/null -xc /dev/null
>/dev/null 2 >&1; then echo "-march=k6"; fi)
+AFLAGS := $(AFLAGS) -DCPU=586
+endif
+
ifdef CONFIG_M686
CFLAGS := $(CFLAGS) -DCPU=686
CFLAGS += $(shell if $(CC) -march=i686 -S -o /dev/null -xc /dev/null
>/dev/null 2>&1; then echo "-march=i686"; fi)
@@ -59,7 +65,7 @@
endif

ifdef CONFIG_MK7
-CFLAGS := $(CFLAGS) -DCPU=686 -march=pentiumpro -mpentiumpro
-malign-functions= 4 -fschedule-insns2 -mwide-multiply
-fexpensive-optimizations
+CFLAGS := $(CFLAGS) -DCPU=686 -malign-functions=4 -fschedule-insns2
-mwide-mult iply -fexpensive-optimizations
CFLAGS += $(shell if $(CC) -march=i686 -S -o /dev/null -xc /dev/null
>/dev/null 2>&1; then echo "-march=i686"; fi)
AFLAGS := $(AFLAGS) -DCPU=686
endif
diff -r -u vanilla-2.3.18ac10/arch/i386/config.in
linux/arch/i386/config.in
--- vanilla-2.3.18ac10/arch/i386/config.in Thu Sep 30 10:58:59 1999
+++ linux/arch/i386/config.in Wed Sep 29 19:45:40 1999
@@ -18,8 +18,9 @@
"386 CONFIG_M386 \
486/Cx486 CONFIG_M486 \
586/K5/5x86/6x86 CONFIG_M586 \
- Pentium/K6/TSC CONFIG_M586TSC \
- PPro/6x86MX CONFIG_M686 \
+ Pentium/TSC/K6 CONFIG_M586TSC \
+ K6-2/K6-III CONFIG_MK6 \
+ PPro/6x86MX CONFIG_M686 \
Athlon CONFIG_MK7" PPro
#
# Define implied options from the CPU selection here
@@ -30,15 +31,14 @@
define_bool CONFIG_X86_BSWAP y
define_bool CONFIG_X86_POPAD_OK y
fi
-if [ "$CONFIG_M686" = "y" -o "$CONFIG_M586TSC" = "y" ]; then
+if [ "$CONFIG_M686" = "y" -o "$CONFIG_M586TSC" = "y" -o \
+ "$CONFIG_MK6" = "y" -o "$CONFIG_MK7" = "y" ]; then
define_bool CONFIG_X86_TSC y
fi
-if [ "$CONFIG_M686" = "y" ]; then
+if [ "$CONFIG_M686" = "y" -o "$CONFIG_MK7" = "y" ]; then
define_bool CONFIG_X86_GOOD_APIC y
fi
-if [ "$CONFIG_MK7" = "y" ]; then
- define_bool CONFIG_X86_TSC y
- define_bool CONFIG_X86_GOOD_APIC y
+if [ "$CONFIG_MK6" = "y" -o "$CONFIG_MK7" = "y" ]; then
define_bool CONFIG_X86_USE_3DNOW y
fi

diff -r -u vanilla-2.3.18ac10/arch/i386/defconfig
linux/arch/i386/defconfig
--- vanilla-2.3.18ac10/arch/i386/defconfig Thu Sep 30 10:58:59 1999
+++ linux/arch/i386/defconfig Wed Sep 29 19:33:18 1999
@@ -16,6 +16,7 @@
# CONFIG_M486 is not set
# CONFIG_M586 is not set
# CONFIG_M586TSC is not set
+# CONFIG_MK6 is not set
CONFIG_M686=y
# CONFIG_MK7 is not set
CONFIG_X86_WP_WORKS_OK=y

***Patch ends***
--------------9402817FF82E473993AD83AD
Content-Type: application/octet-stream;
name="k6-2.3.18ac10.diff.bz2"
Content-Transfer-Encoding: base64
Content-Disposition: attachment;
filename="k6-2.3.18ac10.diff.bz2"

QlpoOTFBWSZTWQX85uoABVJfgHAyXe//+3/v3s6/79/wYAbF3nOO6fe3k72MCrsAKANNEImQ
npqbSNNANqGgAAADTTQPU00CSSTAyZCSP2ohNHpBp6QAaPUAGg0ABwDCMJpiGAQDIAYRpkyY
RgIaCQpIGo0yn6mCI0Ymj0jTR5Qeo9RoA9JoGgDaiQU9Q9TanqDTajEAAM0gA0AAAAVJCTEm
EynpPUwqabU9T9U0DI0B6gekMmIPUyaQQJdeRT0Ddek4tgrEIig+PL3wsys8QlUnuTbvDCCM
WBZnyZSJWxOYN8moO0W1qphAOUQAuVrSWiuYCalrcAQuINgQruGuo0UfRxObp96ais6nSe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QKXg+e
xINwZRVOZVs4HaZY6P9WbS8tKqM1s5mfW0pVWhg1BUS4YFt391KWoVQmKqo+BkKZhhcSrJAi
/KormcqtmaZRLaUucNjkn/54RDK1LjZLrMG9kbm6OLB5ySzQc25r91b+Z26V7Iz7U5w9nwNx
99UsdZZPbOly8/SovJxJgloYMSY+tYxlZbFjfIe/gizhNC8jNhaj5Y3SewmT/Jpz7+x650M5
5c6qqtarm+bhsUMzkNpxTTtNg643NRaJsjy6d7EHJ2HI5viNTlXYm2p6pLTK8lioYv1PiZeP
YybBlDKbDFCuHDBky0a/DeYk7KHJepK43NLmXZsvksWZJlVrWqKlWwWyxbkqMMGIvlSpN5wM
YJhkMkc8TmpsbFHia2g8IYG3dHOWWOdo76PWcG6S/dfpUbbZ2jGFD9peO5KFMBkiE3DJZX56
xH5C90lpA1OsDaUb9jsS9ytyTiUbVSVVeERSq9R47Fl8GpSx7OShXPM5MpW+Nv7LnIzb9JPx
zGRVzUypuvtvH3ZHFiyZ500MKi19Ij28Oyjr12SXs6tYM9McKW9UbzuPGaQ6u2SaFPI6NPSc
ni1HCHAas7dii/cqUnl5/Ll+9aa85THH4LJXpS6ntJg5dhvP/i7kinChIAv5zdQ=
--------------9402817FF82E473993AD83AD--

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/