Messages in this thread |  | | | Subject | Re: FASTCALL in egcs was Re: Kernel 2.1.117 OOPS bug report | | From | Andi Kleen <> | | Date | 22 Aug 1998 13:03:37 +0200 |
| |
In article <k27m02jbc2.fsf@zero.aec.at>, Andi Kleen <ak@muc.de> writes: > In article <Pine.LNX.3.96.980821055644.3089B-100000@penguin.transmeta.com>, > Linus Torvalds <torvalds@transmeta.com> writes: >> On Thu, 20 Aug 1998, rbarnett wrote: >>> >>> I'm using egcs-2.90.27 980315 (egcs-1.0.2 release) with binutils >>> 2.8.1.0.23. >>> >>> Running gdb 4.17 on vmlinux (2.1.117) displays the following output: >>> >>> (gdb) x/10i __switch_to >>> 0xc01088d0 <__switch_to>: pushl %esi >>> 0xc01088d1 <__switch_to+1>: pushl %ebx >>> 0xc01088d2 <__switch_to+2>: movl 0xc(%esp,1),%ebx >>> 0xc01088d6 <__switch_to+6>: movl 0x10(%esp,1),%ecx
>> Ok, egcs for some reason refuses to do the fastcall thing.
>>> Your interpretation? Shall I reinstall GNU gcc and abandon egcs?
>> I wonder. The above certainly implies that at least your particular >> version of egcs cannot compile the current kernels, but I don't know why. >> Before abandoning egcs you might want to talk to some egcs people to see >> whether there is some simple way to make egcs do the right thing.
> The position of Jeffrew Law on this is:
> <quote> >> A new problem that just has appeared today is that Linux 2.1 uses >> __attribute__((regparm)) for some critical functions, and at least egcs 1.0 >> seems to have problems to generate correct code with this in all cases. > Oh god. Please stop them from doing this. regparm does not work on > the x86 and will never work correctly on the x86. They're just going > to shoot themselves in the foot. > </quote>
> So would you consider the appended patch?
> One problem with this (and the workaround in asm-i386/spinlock.h) is > that it adds additional dependencies for loadable kernel modules. But I > don't see a better easy way. Maybe it should be documented somewhere at > least @)
[...]
OK, I withdraw this patch because it is broken. I still think it needs a solution though, probably the best way is to remove FASTCALL completely because it apparently does not even work reliably on 2.7.2.
-Andi
- 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.altern.org/andrebalsa/doc/lkml-faq.html
|  |