public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "hjl dot tools at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/35418]  New: [4.4 Regression]: Revision 132592 miscompiles 172.mgrid
Date: Sat, 01 Mar 2008 22:12:00 -0000	[thread overview]
Message-ID: <bug-35418-682@http.gcc.gnu.org/bugzilla/> (raw)

On Linux/Intel64, gcc 4.4 revision 132592 miscompiles 172.mgrid in SPEC CPU 2K
with -O2 -ffast-math. This part of change:

Index: gcc/fortran/trans-array.c
===================================================================
--- gcc/fortran/trans-array.c   (revision 132591)
+++ gcc/fortran/trans-array.c   (revision 132592)
@@ -3937,10 +3949,10 @@ gfc_trans_array_bounds (tree type, gfc_s

          /* Make sure that negative size arrays are translated
             to being zero size.  */
-         tmp = build2 (GE_EXPR, boolean_type_node,
-                       stride, gfc_index_zero_node);
-         tmp = build3 (COND_EXPR, gfc_array_index_type, tmp,
-                       stride, gfc_index_zero_node);
+         tmp = fold_build2 (GE_EXPR, boolean_type_node,
+                            stride, gfc_index_zero_node);
+         tmp = fold_build3 (COND_EXPR, gfc_array_index_type, tmp,
+                            stride, gfc_index_zero_node);
          gfc_add_modify_expr (pblock, stride, tmp);
         }

miscompiles RESID, which has nested loops on 3-d arrays. Does it ring a bell?


-- 
           Summary: [4.4 Regression]: Revision 132592 miscompiles 172.mgrid
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: hjl dot tools at gmail dot com


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


             reply	other threads:[~2008-03-01 22:12 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-01 22:12 hjl dot tools at gmail dot com [this message]
2008-03-01 22:51 ` [Bug fortran/35418] " hjl dot tools at gmail dot com
2008-03-01 23:00 ` kargl at gcc dot gnu dot org
2008-03-01 23:16 ` tobi at gcc dot gnu dot org
2008-03-02  1:12 ` hjl dot tools at gmail dot com
2008-03-02  1:33 ` kargl at gcc dot gnu dot org
2008-03-02 10:32 ` rguenth at gcc dot gnu dot org
2008-03-02 11:01 ` rguenth at gcc dot gnu dot org
2008-03-05 21:53 ` fxcoudert at gcc dot gnu dot org
2008-03-06 22:03 ` hjl dot tools at gmail dot com
2008-08-22 15:03 ` 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=bug-35418-682@http.gcc.gnu.org/bugzilla/ \
    --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).