public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "jv244 at cam dot ac dot uk" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/41403] miscompilation of goto/label using code
Date: Sat, 19 Sep 2009 18:48:00 -0000	[thread overview]
Message-ID: <20090919184841.28446.qmail@sourceware.org> (raw)
In-Reply-To: <bug-41403-10743@http.gcc.gnu.org/bugzilla/>



------- Comment #5 from jv244 at cam dot ac dot uk  2009-09-19 18:48 -------
and also fails in C

#include <stdio.h>
main()
{
  int i;
  int i0;
  void * i1;
  int icon01;
  int ivfail;
  int ivpass;
  int D1545;

  ivfail = 0;
  i0 = -1;
  i1 = &&label_001263;
  if (i1 == &&label_001262) goto label_001262;
  if (i1 == &&label_001263) goto label_001263;
  if (i1 == &&label_001264) goto label_001264;
  label_001262:
  icon01 = 1262;
  goto label_001265;
  label_001263:
  icon01 = 1263;
  goto label_001265;
  label_001264:
  icon01 = 1264;
  label_001265:
  label_041260:

    D1545 = icon01 + -1263;
    if (D1545 != 0) goto label_021260; else goto label_011260;
  label_011260:;
  ivpass = ivpass + 1;
  goto label_001271;
  label_021260:
  ivfail = ivfail + 1;
  label_001271:
  printf("%d\n",ivfail);
}


-- 

jv244 at cam dot ac dot uk changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P2
            Summary|Optimization: NIST test     |miscompilation of goto/label
                   |FM013.f fails at -O1 and    |using code
                   |above                       |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41403


  parent reply	other threads:[~2009-09-19 18:48 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-19  5:42 [Bug fortran/41403] New: Optimization: NIST test FM013.f fails at -O1 and above jvdelisle at gcc dot gnu dot org
2009-09-19  5:44 ` [Bug fortran/41403] " jvdelisle at gcc dot gnu dot org
2009-09-19  5:47 ` jvdelisle at gcc dot gnu dot org
2009-09-19  6:15 ` jvdelisle at gcc dot gnu dot org
2009-09-19 18:27 ` [Bug middle-end/41403] " jv244 at cam dot ac dot uk
2009-09-19 18:48 ` jv244 at cam dot ac dot uk [this message]
2009-09-19 18:54 ` [Bug middle-end/41403] miscompilation of goto/label using code jv244 at cam dot ac dot uk
2009-09-20 13:18 ` [Bug middle-end/41403] [4.3/4.4/4.5 Regression] " jv244 at cam dot ac dot uk
2009-09-20 14:05 ` [Bug fortran/41403] " rguenth at gcc dot gnu dot org
2009-09-20 14:18 ` jv244 at cam dot ac dot uk
2009-09-20 14:44 ` rguenth at gcc dot gnu dot org
2009-09-20 17:04 ` jvdelisle at verizon dot net
2009-09-20 17:09 ` rguenth at gcc dot gnu dot org
2009-10-02 16:26 ` domob at gcc dot gnu dot org
2009-10-03 14:13 ` domob at gcc dot gnu dot org
2009-10-05 13:16 ` domob at gcc dot gnu dot org
2009-10-05 13:19 ` domob at gcc dot gnu dot org
2009-10-05 13:26 ` [Bug fortran/41403] [4.3/4.4 " rguenth 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=20090919184841.28446.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).