unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: Christopher Cramer <crayc@pyro.net>
Cc: guile-devel@gnu.org
Subject: Re: bug in throw.c
Date: Tue, 8 Apr 2003 01:31:06 -0500	[thread overview]
Message-ID: <20030408013106.A8696@kiwi.pyrotechnics.com> (raw)
In-Reply-To: <20030407000136.0F81D8B7@panda.mostang.com>; from davidm@mostang.com on Sun, Apr 06, 2003 at 05:01:36PM -0700

On Sun, Apr 06, 2003 at 05:01:36PM -0700, David Mosberger-Tang wrote:
> #if 0/*def __GNUC__*/
>   /* Dirk:FIXME:: This bugfix should be removed some time. */
>   /* GCC 2.95.2 has a bug in its optimizer that makes it generate
>      incorrect code sometimes.  This barrier stops it from being too
>      clever. */
>   asm volatile ("" : "=g" (winds));
> #endif
> 
> This is clearly bogus: the asm statement claims that it's writing the
> "winds" variable, which isn't true.  On ia64, this has the effect that
> the "winds" gets corrupted and comes out with value "1".  Just

Now, I haven't checked up on the changes in recent GCC versions, but
that behavior seems really odd to me. How does it change the value of a
variable if you put in an empty asm statement that only claims to change
the variable?

This is a common tactic to defeat the optimizer. I don't understand
why GCC would suddenly have problems with this.

-- 
Christopher Cramer <crayc@pyro.net> <http://www.pyro.net/~crayc/>
"People said it couldn't be that our soldiers would do such things. Now
you read worse things in the mainstream media and people don't care. We
used to say that if only people know about it, it would stop. Now they
know about it, and it hasn't stopped." - Adam Keller


_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://mail.gnu.org/mailman/listinfo/guile-devel


  reply	other threads:[~2003-04-08  6:31 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-04-07  0:01 bug in throw.c David Mosberger-Tang
2003-04-08  6:31 ` Christopher Cramer [this message]
2003-04-08  6:44   ` David Mosberger-Tang
2003-04-11  3:24 ` Rob Browning
2003-05-03 21:47   ` Marius Vollmer
2003-05-03 21:56     ` Marius Vollmer

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

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030408013106.A8696@kiwi.pyrotechnics.com \
    --to=crayc@pyro.net \
    --cc=guile-devel@gnu.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 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).