From: Willy Tarreau <w@1wt.eu>
To: "H. Peter Anvin" <hpa@zytor.com>
Cc: Segher Boessenkool <segher@kernel.crashing.org>,
Axel Reinhold <axel@freakout.de>,
linux-kernel@vger.kernel.org
Subject: Re: Kernel Bug in 2.4.35 when compiled gcc>=4.2.0 and -march=c3
Date: Mon, 6 Aug 2007 19:45:36 +0200 [thread overview]
Message-ID: <20070806174536.GA12131@1wt.eu> (raw)
In-Reply-To: <46B75CD0.7080408@zytor.com>
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
next prev parent reply other threads:[~2007-08-06 17:48 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-05 8:56 Kernel Bug in 2.4.35 when compiled gcc>=4.2.0 and -march=c3 Axel Reinhold
2007-08-05 9:49 ` Willy Tarreau
2007-08-05 15:43 ` Willy Tarreau
2007-08-05 19:17 ` Willy Tarreau
2007-08-06 13:05 ` Segher Boessenkool
2007-08-06 13:26 ` Willy Tarreau
2007-08-06 17:39 ` H. Peter Anvin
2007-08-06 17:45 ` Willy Tarreau [this message]
2007-08-06 18:01 ` H. Peter Anvin
2007-08-06 19:13 ` Willy Tarreau
2007-08-06 21:15 ` Segher Boessenkool
2007-08-06 21:16 ` Willy Tarreau
2007-08-07 5:04 ` Axel Reinhold
2007-08-07 8:12 ` Willy Tarreau
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070806174536.GA12131@1wt.eu \
--to=w@1wt.eu \
--cc=axel@freakout.de \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=segher@kernel.crashing.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.