From: "M. Warner Losh" <imp@bsdimp.com>
To: qemu-devel@nongnu.org, weil@mail.berlios.de
Subject: Re: [Qemu-devel] Re: [PATCH 2/2] Add __noreturn function attribute
Date: Sun, 30 Nov 2008 10:21:59 -0700 (MST) [thread overview]
Message-ID: <20081130.102159.1628339025.imp@bsdimp.com> (raw)
In-Reply-To: <49328C7F.1050705@mail.berlios.de>
In message: <49328C7F.1050705@mail.berlios.de>
Stefan Weil <weil@mail.berlios.de> writes:
: Jan Kiszka schrieb:
: > Laurent Desnogues wrote:
: >> On Sun, Nov 30, 2008 at 12:51 PM, Stefan Weil <berlios@weilnetz.de>
: >> wrote:
: >>> Why do we need a new macro instead of just using __attribute__
: >>> ((__noreturn__))?
: >> Don't we need it to prevent gcc-ism from being all over the code?
: >
: > Yep, and that's also why we need wrapping. You can easily define it away
: > if your compiler doesn't support it. We just need to add the required
: > conditions.
: >
: >> Though I wonder how much tcg converted code still depends on
: >> being compiled by gcc.
: >
: > I guess once the hard dependencies are removed, fixing things like the
: > existing __attributes__ etc. will just be mechanical work.
: >
: > Jan
: >
:
:
: For compilers which don't support __attributes__, a simple
:
: #define __attributes__(dummy) /* dummy */
:
: or an equivalent command line option would eliminate all gcc-isms.
: I don't think we need wrapping, at least not now.
This doesn't work so well when 'dummy' is __packed__.
The BSD projects have had similar macros for a long long time, and
they work out well in practice.
Warner
next prev parent reply other threads:[~2008-11-30 17:24 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-28 11:47 [Qemu-devel] [PATCH 2/2] Add __noreturn function attribute Jan Kiszka
2008-11-28 17:35 ` malc
2008-11-28 17:56 ` [Qemu-devel] " Jan Kiszka
2008-11-28 18:28 ` Thiemo Seufer
2008-11-30 10:08 ` Avi Kivity
2008-11-30 11:51 ` Stefan Weil
2008-11-30 12:00 ` Laurent Desnogues
2008-11-30 12:38 ` Jan Kiszka
2008-11-30 12:52 ` Stefan Weil
2008-11-30 13:37 ` Andreas Färber
2008-11-30 17:21 ` M. Warner Losh [this message]
2008-11-30 12:33 ` Jan Kiszka
2008-11-30 13:11 ` Thiemo Seufer
2008-11-30 14:36 ` Jan Kiszka
2008-12-02 19:49 ` Anthony Liguori
2008-12-04 16:44 ` Jan Kiszka
2008-12-04 18:39 ` Jan Kiszka
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=20081130.102159.1628339025.imp@bsdimp.com \
--to=imp@bsdimp.com \
--cc=qemu-devel@nongnu.org \
--cc=weil@mail.berlios.de \
/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.