[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20070806174536.GA12131@1wt.eu>
Date: Mon, 6 Aug 2007 19:45:36 +0200
From: Willy Tarreau <w@....eu>
To: "H. Peter Anvin" <hpa@...or.com>
Cc: Segher Boessenkool <segher@...nel.crashing.org>,
Axel Reinhold <axel@...akout.de>, linux-kernel@...r.kernel.org
Subject: Re: Kernel Bug in 2.4.35 when compiled gcc>=4.2.0 and -march=c3
On Mon, Aug 06, 2007 at 10:39:28AM -0700, H. Peter Anvin wrote:
> Willy Tarreau wrote:
> >
> > Just to enlighten me on the subject, could you please explain me
> > what is wrong in the code ? Granted I found it awful, but even on
> > the GCC-4.2 page where -fno-toplevel-reorder is explained, it is
> > said that asm statements can be instantiated between functions
> > blocks, which is exactly what is used here.
> >
>
> A stray semicolon:
>
> __attribute__((regparm(0))) void call_do_IRQ(void); __asm__(...
>
> ... is actually a prototype followed by a top-level asm statement
> (because of the semicolon), *not* a function with a single-statement
> body (which is itself uglier than hell, use braces please...)
I'm well aware of that, even in the example I wrote to reproduce the issue
and posted to gcc's bugzilla, I clearly have one function prototype and a
separate asm statement which contained a label with the function's name.
So in my opinion, the code above is not buggy. It's dirty (though I did
not find how to produce the equivalent in a different manner).
Willy
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists