public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/57185] New: ICE: Segmentation fault in add_field_for_reduction with -ftree-parallelize-loops=2 -fipa-pta
@ 2013-05-06 11:59 antoine.balestrat at gmail dot com
  2013-05-06 12:09 ` [Bug tree-optimization/57185] [4.8/4.9 Regression] " rguenth at gcc dot gnu.org
  2013-05-07  8:13 ` rguenth at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: antoine.balestrat at gmail dot com @ 2013-05-06 11:59 UTC (permalink / raw)
  To: gcc-bugs


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

             Bug #: 57185
           Summary: ICE: Segmentation fault in add_field_for_reduction
                    with -ftree-parallelize-loops=2 -fipa-pta
    Classification: Unclassified
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: antoine.balestrat@gmail.com


Using GCC 4.9.0 as of 20130506 :

$ cat kk.c

int a, b;
int *d;
void f(void)
{
    int c;
    b %= 1;

    if(1 - (b < 1))
    {
        int *q = 0;

        if(a)
        {
            c = 0;
lbl:
            for(*d; *d; ++*d)
                if(c ? : a ? : (c = 1) ? : 0)
                    *q &= 1;
            return;
        }

        q = 1;
    }
    goto lbl;
}

$ xgcc -O3 -w -ftree-parallelize-loops=2 -fipa-pta kk.c

kk.c: In function ‘f’:
kk.c:3:1: internal compiler error: Segmentation fault
void f(void)
     ^
0x90c35f crash_signal
    ../../srcdir/gcc/toplev.c:333
0x9906d0 add_field_for_reduction(reduction_info**, tree_node*)
    ../../srcdir/gcc/tree-parloops.c:967
0x992a52 traverse_noresize<tree_node*, add_field_for_reduction>
    ../../srcdir/gcc/hash-table.h:928
0x992a52 traverse<tree_node*, add_field_for_reduction>
    ../../srcdir/gcc/hash-table.h:950
0x992a52 separate_decls_in_region
    ../../srcdir/gcc/tree-parloops.c:1359
0x9948e5 gen_parallel_loop
    ../../srcdir/gcc/tree-parloops.c:1868
0x9948e5 parallelize_loops()
    ../../srcdir/gcc/tree-parloops.c:2218
0xa1c982 tree_parallelize_loops
    ../../srcdir/gcc/tree-ssa-loop.c:559
0xa1c982 tree_parallelize_loops
    ../../srcdir/gcc/tree-ssa-loop.c:554
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.
>From gcc-bugs-return-421690-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon May 06 12:05:00 2013
Return-Path: <gcc-bugs-return-421690-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 29120 invoked by alias); 6 May 2013 12:05:00 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 29068 invoked by uid 48); 6 May 2013 12:04:52 -0000
From: "rguenth at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/57185] ICE: Segmentation fault in add_field_for_reduction with -ftree-parallelize-loops=2 -fipa-pta
Date: Mon, 06 May 2013 12:05:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: tree-optimization
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: rguenth at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: rguenth at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Changed-Fields: Status Last reconfirmed AssignedTo Ever Confirmed
Message-ID: <bug-57185-4-sHNbUkJ517@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-57185-4@http.gcc.gnu.org/bugzilla/>
References: <bug-57185-4@http.gcc.gnu.org/bugzilla/>
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
Content-Type: text/plain; charset="UTF-8"
MIME-Version: 1.0
X-SW-Source: 2013-05/txt/msg00363.txt.bz2
Content-length: 647


http://gcc.gnu.org/bugzilla/show_bug.cgi?idW185

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|                            |2013-05-06
         AssignedTo|unassigned at gcc dot       |rguenth at gcc dot gnu.org
                   |gnu.org                     |
     Ever Confirmed|0                           |1

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> 2013-05-06 12:04:52 UTC ---
Mine.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug tree-optimization/57185] [4.8/4.9 Regression] ICE: Segmentation fault in add_field_for_reduction with -ftree-parallelize-loops=2 -fipa-pta
  2013-05-06 11:59 [Bug tree-optimization/57185] New: ICE: Segmentation fault in add_field_for_reduction with -ftree-parallelize-loops=2 -fipa-pta antoine.balestrat at gmail dot com
@ 2013-05-06 12:09 ` rguenth at gcc dot gnu.org
  2013-05-07  8:13 ` rguenth at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: rguenth at gcc dot gnu.org @ 2013-05-06 12:09 UTC (permalink / raw)
  To: gcc-bugs


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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to work|                            |4.7.2
   Target Milestone|---                         |4.8.1
            Summary|ICE: Segmentation fault in  |[4.8/4.9 Regression] ICE:
                   |add_field_for_reduction     |Segmentation fault in
                   |with                        |add_field_for_reduction
                   |-ftree-parallelize-loops=2  |with
                   |-fipa-pta                   |-ftree-parallelize-loops=2
                   |                            |-fipa-pta
      Known to fail|                            |4.8.0

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> 2013-05-06 12:09:42 UTC ---
Index: gcc/tree-parloops.c
===================================================================
--- gcc/tree-parloops.c (revision 198625)
+++ gcc/tree-parloops.c (working copy)
@@ -964,9 +964,9 @@ add_field_for_reduction (reduction_info
 {

   struct reduction_info *const red = *slot;
-  tree var = SSA_NAME_VAR (gimple_assign_lhs (red->reduc_stmt));
-  tree field = build_decl (gimple_location (red->reduc_stmt),
-                          FIELD_DECL, DECL_NAME (var), TREE_TYPE (var));
+  tree var = gimple_assign_lhs (red->reduc_stmt);
+  tree field = build_decl (gimple_location (red->reduc_stmt), FIELD_DECL,
+                          SSA_NAME_IDENTIFIER (var), TREE_TYPE (var));

   insert_field_into_struct (type, field);


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug tree-optimization/57185] [4.8/4.9 Regression] ICE: Segmentation fault in add_field_for_reduction with -ftree-parallelize-loops=2 -fipa-pta
  2013-05-06 11:59 [Bug tree-optimization/57185] New: ICE: Segmentation fault in add_field_for_reduction with -ftree-parallelize-loops=2 -fipa-pta antoine.balestrat at gmail dot com
  2013-05-06 12:09 ` [Bug tree-optimization/57185] [4.8/4.9 Regression] " rguenth at gcc dot gnu.org
@ 2013-05-07  8:13 ` rguenth at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: rguenth at gcc dot gnu.org @ 2013-05-07  8:13 UTC (permalink / raw)
  To: gcc-bugs


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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED

--- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> 2013-05-07 08:12:59 UTC ---
Author: rguenth
Date: Mon May  6 15:06:41 2013
New Revision: 198630

URL: http://gcc.gnu.org/viewcvs?rev=198630&root=gcc&view=rev
Log:
2013-05-06  Richard Biener  <rguenther@suse.de>

    PR tree-optimization/57185
    * tree-parloops.c (add_field_for_reduction): Handle anonymous
    SSA names properly.

    * gcc.dg/autopar/pr57185.c: New testcase.

Added:
    trunk/gcc/testsuite/gcc.dg/autopar/pr57185.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree-parloops.c


Author: rguenth
Date: Tue May  7 08:11:46 2013
New Revision: 198665

URL: http://gcc.gnu.org/viewcvs?rev=198665&root=gcc&view=rev
Log:
2013-05-07  Richard Biener  <rguenther@suse.de>

    Backport from mainline
    2013-05-06  Richard Biener  <rguenther@suse.de>

    PR tree-optimization/57185
    * tree-parloops.c (add_field_for_reduction): Handle anonymous
    SSA names properly.

    * gcc.dg/autopar/pr57185.c: New testcase.

    2013-04-19  Richard Biener  <rguenther@suse.de>

    PR tree-optimization/57000
    * tree-ssa-reassoc.c (pass_reassoc): Add TODO_update_ssa_only_virtuals.

    * gcc.dg/tree-ssa/reassoc-27.c: New testcase.

Added:
    branches/gcc-4_8-branch/gcc/testsuite/gcc.dg/autopar/pr57185.c
    branches/gcc-4_8-branch/gcc/testsuite/gcc.dg/tree-ssa/reassoc-27.c
Modified:
    branches/gcc-4_8-branch/gcc/ChangeLog
    branches/gcc-4_8-branch/gcc/testsuite/ChangeLog
    branches/gcc-4_8-branch/gcc/tree-parloops.c


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-05-07  8:13 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-06 11:59 [Bug tree-optimization/57185] New: ICE: Segmentation fault in add_field_for_reduction with -ftree-parallelize-loops=2 -fipa-pta antoine.balestrat at gmail dot com
2013-05-06 12:09 ` [Bug tree-optimization/57185] [4.8/4.9 Regression] " rguenth at gcc dot gnu.org
2013-05-07  8:13 ` rguenth at gcc dot gnu.org

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).