public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "law at redhat dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/30984] [4.1/4.2/4.3 Regression] ICE with computed goto and constants
Date: Mon, 12 Mar 2007 20:06:00 -0000 [thread overview]
Message-ID: <20070312200626.29541.qmail@sourceware.org> (raw)
In-Reply-To: <bug-30984-6528@http.gcc.gnu.org/bugzilla/>
------- Comment #3 from law at redhat dot com 2007-03-12 20:06 -------
Subject: Re: [4.1/4.2/4.3 Regression] ICE with
computed goto and constants
On Mon, 2007-03-12 at 19:45 +0000, janis at gcc dot gnu dot org wrote:
>
> ------- Comment #2 from janis at gcc dot gnu dot org 2007-03-12 19:45 -------
> A regression hunt on powerpc-linux using the submitter's test case identified
> this patch:
>
> http://gcc.gnu.org/viewcvs?view=rev&rev=96084
>
> r96084 | law | 2005-03-08 03:39:19 +0000 (Tue, 08 Mar 2005)
Thanks for alerting me to this problem. I think the right fix is going
to simply be to enforce a rule that we can only optimize a computed goto
if the argument collapses down to a local LABEL_REF rather than a
generic invariant.
In the case where we have a constant or non-local LABEL_REF, the CFG
(before optimizing) ought to be conservatively correct(*). Optimizing
is impossible because we don't know which outgoing edge to keep and
which ones to throw away.
This ought to be a 1-2 line fix.
Jeff
(*) If the argument referred to a constant address in the current
function which does not correspond to any known addressable LABEL_REF
then we're hosed as the original unoptimized CFG is probably bogus.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30984
next prev parent reply other threads:[~2007-03-12 20:06 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-02-27 19:07 [Bug middle-end/30984] New: " pinskia at gcc dot gnu dot org
2007-03-03 21:47 ` [Bug middle-end/30984] [4.1/4.2/4.3 Regression] " pinskia at gcc dot gnu dot org
2007-03-05 4:10 ` mmitchel at gcc dot gnu dot org
2007-03-12 19:45 ` janis at gcc dot gnu dot org
2007-03-12 20:06 ` law at redhat dot com [this message]
2007-03-12 23:47 ` spark at gcc dot gnu dot org
2007-03-13 0:06 ` law at redhat dot com
2007-03-13 16:33 ` law at redhat dot com
2007-03-19 19:52 ` [Bug tree-optimization/30984] " law at gcc dot gnu dot org
2007-03-19 19:52 ` law at redhat dot com
2007-03-19 20:03 ` law at gcc dot gnu dot org
2007-03-19 20:04 ` law at redhat dot com
2007-03-19 20:04 ` law at gcc dot gnu dot org
2007-04-28 4:19 ` kargl at gcc dot gnu dot org
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=20070312200626.29541.qmail@sourceware.org \
--to=gcc-bugzilla@gcc.gnu.org \
--cc=gcc-bugs@gcc.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).