Messages in this thread Patch in this message | | | Date | Sun, 26 Nov 2000 20:55:40 +0100 | From | "J . A . Magallon" <> | Subject | Re: gcc-2.95.2-51 is buggy |
| |
On Sun, 26 Nov 2000 16:33:25 Olaf Dietsche wrote: > > A simple `gcc -march=i686' or `gcc -mpentiumpro' does fix it as > well. So, if you configure your kernel with `CONFIG_M686=y' the problem > should be gone. >
That does not work for 2.2 kernels. Always compile for -m486. To use the -march flag you need to modify arch/i386/kernel/Makefile. Patch follows:
================= PATCH patch-gcc-arch: --- linux-2.2.17/arch/i386/Makefile.orig Wed Nov 22 20:42:49 2000 +++ linux-2.2.17/arch/i386/Makefile Wed Nov 22 20:44:40 2000 @@ -24,23 +24,23 @@ CFLAGS := $(CFLAGS) $(CFLAGS_PIPE) $(CFLAGS_NSR) ifdef CONFIG_M386 -CFLAGS := $(CFLAGS) -m386 -DCPU=386 +CFLAGS := $(CFLAGS) -march=i386 -DCPU=386 endif ifdef CONFIG_M486 -CFLAGS := $(CFLAGS) -m486 -DCPU=486 +CFLAGS := $(CFLAGS) -march=i486 -DCPU=486 endif ifdef CONFIG_M586 -CFLAGS := $(CFLAGS) -m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=586 +CFLAGS := $(CFLAGS) -march=i586 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=586 endif ifdef CONFIG_M586TSC -CFLAGS := $(CFLAGS) -m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=586 +CFLAGS := $(CFLAGS) -march=i586 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=586 endif ifdef CONFIG_M686 -CFLAGS := $(CFLAGS) -m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=686 +CFLAGS := $(CFLAGS) -march=i686 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=686 endif HEAD := arch/i386/kernel/head.o arch/i386/kernel/init_task.o
-- Juan Antonio Magallon Lacarta #> cd /pub mailto:jamagallon@able.es #> more beer
Linux 2.2.18-pre23-vm #3 SMP Wed Nov 22 22:33:53 CET 2000 i686 unknown
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/
| |