public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Hans-Peter Nilsson <hans-peter.nilsson@axis.com>
To: gni@gecko.de
Cc: hans-peter.nilsson@axis.com, gcc@gcc.gnu.org
Subject: Re: decl_conflicts_with_clobbers_p problem
Date: Fri, 14 Mar 2003 13:46:00 -0000	[thread overview]
Message-ID: <200303141214.h2ECEqOi001997@ignucius.axis.se> (raw)
In-Reply-To: <20030314112118.GA58645@lorien.int.gecko.de> (message from Gunther Nikl on Fri, 14 Mar 2003 12:21:18 +0100)

> Date: Fri, 14 Mar 2003 12:21:18 +0100
> From: Gunther Nikl <gni@gecko.de>

> > Or without code changes elsewhere than
> > the macro definition, use a trick like
> >  #define LP1NR(offs, name, t1, v1, r1, bt, bn) LP1NR_##r1 (offs, name, t1, v1, bt, bn)
> > and define different
> >  #define LP1NR_a1(offs, name, t1, v1, r1, bt, bn) ...
> >  #define LP1NR_d0(offs, name, t1, v1, r1, bt, bn) ...
> > with contents where each different "r1" is listed as output and
> > not in the clobber list?  Or just parametrize the clobber list?
> 
>   This would result in a lot of macros because the arguments are in a
>   "random" order and unpredictable.

So there's not just *one* register, as was in your example?
That information was missing from your email.  Sorry, then I'm
all out of suggestions.

> > You *have* to list the register that is changed as output.  This
> > is not really a change; your asm was in error before too, GCC
> > just didn't notice; it'd silently generated wrong code instead.
> 
>   Yes, according the (3.x?) documentation the asm is wrong.

As I said, the documentation also said that before the error
message was implemented.

> However, I have
>   never seen incorrect code beeing generated (which doesn't prove anything,
>   granted) and I have used GCC alot on the system in question where these
>   asm statements are required.

Well, a programmer here saw it happen.  See the URL I quoted.
That's really enough, isn't it?  Having GCC corrected to work
according to the documentation saves *you* the trouble to trip
over a code-generation compiler bug.  I can't really understand
your argument.

>   I guess creating an appropriate macro for every function is the only
>   viable solution.

Well, good, you found a solution.

brgds, H-P

  reply	other threads:[~2003-03-14 12:14 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-03-13  9:46 Gunther Nikl
2003-03-13 10:21 ` Andreas Schwab
2003-03-13 11:07   ` Gunther Nikl
2003-03-13 12:12     ` Andreas Schwab
2003-03-13 17:54       ` Gunther Nikl
2003-03-13 18:32 ` Hans-Peter Nilsson
2003-03-14 12:02   ` Gunther Nikl
2003-03-14 13:46     ` Hans-Peter Nilsson [this message]
2003-03-14 16:21       ` Gunther Nikl
2003-03-14 17:17         ` Hans-Peter Nilsson
2003-03-17 15:55           ` extended asm (Was: Re: decl_conflicts_with_clobbers_p problem) Gunther Nikl
2003-03-17 17:32             ` Hans-Peter Nilsson
2003-03-21 15:26               ` Gunther Nikl
2003-03-24 11:04               ` GCC 3.3 release Gunther Nikl
2003-03-24 13:43                 ` Andreas Schwab
2003-03-24 14:40                   ` Gunther Nikl
2003-03-25 11:20                   ` Gunther Nikl

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=200303141214.h2ECEqOi001997@ignucius.axis.se \
    --to=hans-peter.nilsson@axis.com \
    --cc=gcc@gcc.gnu.org \
    --cc=gni@gecko.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).