public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/58343] New: ICE in dfs_enumerate_from, at cfganal.c:1036
@ 2013-09-07  3:46 su at cs dot ucdavis.edu
  2013-09-09  8:40 ` [Bug tree-optimization/58343] [4.9 Regression] " rguenth at gcc dot gnu.org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: su at cs dot ucdavis.edu @ 2013-09-07  3:46 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 58343
           Summary: ICE in dfs_enumerate_from, at cfganal.c:1036
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: su at cs dot ucdavis.edu

The following code causes an ICE when compiled with the current gcc trunk at
-O1 and above on x86_64-linux (both 32-bit and 64-bit modes). 

This is a regression from 4.8.x. 

$ gcc-trunk -v
Using built-in specs.
COLLECT_GCC=gcc-trunk
COLLECT_LTO_WRAPPER=/usr/local/gcc-trunk/libexec/gcc/x86_64-unknown-linux-gnu/4.9.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-trunk/configure
--enable-languages=c,c++,objc,obj-c++,fortran,lto
--with-gmp=/usr/local/gcc-trunk --with-mpfr=/usr/local/gcc-trunk
--with-mpc=/usr/local/gcc-trunk --with-cloog=/usr/local/gcc-trunk
--prefix=/usr/local/gcc-trunk
Thread model: posix
gcc version 4.9.0 20130906 (experimental) [trunk revision 202308] (GCC) 
$ gcc-trunk -O0 small.c
$ gcc-4.8 -O1 small.c
$ gcc-trunk -O1 small.c
small.c: In function ‘main’:
small.c:3:5: internal compiler error: in dfs_enumerate_from, at cfganal.c:1036
 int main ()
     ^
0x608c4b dfs_enumerate_from(basic_block_def*, int, bool (*)(basic_block_def
const*, void const*), basic_block_def**, int, void const*)
    ../../gcc-trunk/gcc/cfganal.c:1036
0xa96d66 determine_bb_domination_status
    ../../gcc-trunk/gcc/tree-ssa-threadupdate.c:825
0xa96d66 thread_through_loop_header
    ../../gcc-trunk/gcc/tree-ssa-threadupdate.c:995
0xa96d66 thread_through_all_blocks(bool)
    ../../gcc-trunk/gcc/tree-ssa-threadupdate.c:1279
0x9fabab tree_ssa_dominator_optimize
    ../../gcc-trunk/gcc/tree-ssa-dom.c:849
0x9fabab execute
    ../../gcc-trunk/gcc/tree-ssa-dom.c:951
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.
$ 


-------------------------

int a;

int main ()
{
  int b = a; 

  for (a = 1; a > 0; a--)
    ;

 lbl:
  if (b && a)
    goto lbl; 

  return 0;
}
>From gcc-bugs-return-429176-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sat Sep 07 04:02:04 2013
Return-Path: <gcc-bugs-return-429176-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 6636 invoked by alias); 7 Sep 2013 04:02:04 -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 6558 invoked by uid 48); 7 Sep 2013 04:02:00 -0000
From: "su at cs dot ucdavis.edu" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/58344] New: ICE with segfault at -O1 and above on x86_64-linux-gnu
Date: Sat, 07 Sep 2013 04:02:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: su at cs dot ucdavis.edu
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter
Message-ID: <bug-58344-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2013-09/txt/msg00416.txt.bz2
Content-length: 2603

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

            Bug ID: 58344
           Summary: ICE with segfault at -O1 and above on x86_64-linux-gnu
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: su at cs dot ucdavis.edu

The following code causes an ICE when compiled with the current gcc trunk at
-O1 and above on x86_64-linux (both 32-bit and 64-bit modes). 

This is a regression from 4.8.x. 


$ gcc-trunk -v
Using built-in specs.
COLLECT_GCC=gcc-trunk
COLLECT_LTO_WRAPPER=/usr/local/gcc-trunk/libexec/gcc/x86_64-unknown-linux-gnu/4.9.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-trunk/configure
--enable-languages=c,c++,objc,obj-c++,fortran,lto
--with-gmp=/usr/local/gcc-trunk --with-mpfr=/usr/local/gcc-trunk
--with-mpc=/usr/local/gcc-trunk --with-cloog=/usr/local/gcc-trunk
--prefix=/usr/local/gcc-trunk
Thread model: posix
gcc version 4.9.0 20130906 (experimental) [trunk revision 202308] (GCC) 
$ gcc-trunk -O0 -c small.c
$ gcc-4.8 -O1 -c small.c
$ gcc-trunk -O1 -c small.c
small.c: In function ‘foo’:
small.c:9:7: internal compiler error: Segmentation fault
   bar (a[0]);
       ^
0x924b2f crash_signal
    ../../gcc-trunk/gcc/toplev.c:335
0x6daba0 expand_expr_real_1(tree_node*, rtx_def*, machine_mode,
expand_modifier, rtx_def**)
    ../../gcc-trunk/gcc/expr.c:9758
0x5fc8ca expand_expr
    ../../gcc-trunk/gcc/expr.h:444
0x5fc8ca store_one_arg
    ../../gcc-trunk/gcc/calls.c:4502
0x6024f2 expand_call(tree_node*, rtx_def*, int)
    ../../gcc-trunk/gcc/calls.c:3042
0x6dbc2e expand_expr_real_1(tree_node*, rtx_def*, machine_mode,
expand_modifier, rtx_def**)
    ../../gcc-trunk/gcc/expr.c:10234
0x612b6f expand_call_stmt
    ../../gcc-trunk/gcc/cfgexpand.c:2180
0x612b6f expand_gimple_stmt_1
    ../../gcc-trunk/gcc/cfgexpand.c:2218
0x612b6f expand_gimple_stmt
    ../../gcc-trunk/gcc/cfgexpand.c:2370
0x6139b3 expand_gimple_basic_block
    ../../gcc-trunk/gcc/cfgexpand.c:4204
0x61557c gimple_expand_cfg
    ../../gcc-trunk/gcc/cfgexpand.c:4723
0x61557c execute
    ../../gcc-trunk/gcc/cfgexpand.c:4937
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.
$ 


-----------------------------------


struct U {};

static struct U a[1];

extern void bar (struct U);

void foo ()
{
  bar (a[0]);
}
>From gcc-bugs-return-429177-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sat Sep 07 04:18:37 2013
Return-Path: <gcc-bugs-return-429177-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 16676 invoked by alias); 7 Sep 2013 04:18:36 -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 16637 invoked by uid 48); 7 Sep 2013 04:18:32 -0000
From: "su at cs dot ucdavis.edu" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug ipa/58345] New: ICE with SIGFPE at -O1 on x86_64-linux-gnu (affecting trunk and 4.8)
Date: Sat, 07 Sep 2013 04:18:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: ipa
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: su at cs dot ucdavis.edu
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter
Message-ID: <bug-58345-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2013-09/txt/msg00417.txt.bz2
Content-length: 5355

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

            Bug ID: 58345
           Summary: ICE with SIGFPE at -O1 on x86_64-linux-gnu (affecting
                    trunk and 4.8)
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: ipa
          Assignee: unassigned at gcc dot gnu.org
          Reporter: su at cs dot ucdavis.edu

The following code causes an ICE when compiled with the current gcc trunk and
4.8 at -O1 only on x86_64-linux (both 32-bit and 64-bit modes). 

This is a regression from 4.7.x. 

$ gcc-trunk -v
Using built-in specs.
COLLECT_GCC=gcc-trunk
COLLECT_LTO_WRAPPER=/usr/local/gcc-trunk/libexec/gcc/x86_64-unknown-linux-gnu/4.9.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-trunk/configure
--enable-languages=c,c++,objc,obj-c++,fortran,lto
--with-gmp=/usr/local/gcc-trunk --with-mpfr=/usr/local/gcc-trunk
--with-mpc=/usr/local/gcc-trunk --with-cloog=/usr/local/gcc-trunk
--prefix=/usr/local/gcc-trunk
Thread model: posix
gcc version 4.9.0 20130906 (experimental) [trunk revision 202308] (GCC) 
$ gcc-trunk -O0 -c small.c
$ gcc-trunk -O2 -c small.c
$ gcc-trunk -O3 -c small.c
$ gcc-trunk -Os -c small.c
$ gcc-4.7 -O1 -c small.c
$ gcc-trunk -O1 -c small.c
small.c: In function ‘foo’:
small.c:7:6: internal compiler error: Floating point exception
 void foo ()
      ^
0x924b2f crash_signal
    ../../gcc-trunk/gcc/toplev.c:335
0x77ecd3 fold_array_ctor_reference
    ../../gcc-trunk/gcc/gimple-fold.c:2816
0x77ecd3 fold_ctor_reference
    ../../gcc-trunk/gcc/gimple-fold.c:2964
0x7827d2 fold_const_aggregate_ref_1(tree_node*, tree_node* (*)(tree_node*))
    ../../gcc-trunk/gcc/gimple-fold.c:3066
0x78443b fold_const_aggregate_ref
    ../../gcc-trunk/gcc/gimple-fold.c:3088
0x78443b maybe_fold_reference
    ../../gcc-trunk/gcc/gimple-fold.c:272
0x784df6 gimple_fold_call
    ../../gcc-trunk/gcc/gimple-fold.c:1091
0x784df6 fold_stmt_1
    ../../gcc-trunk/gcc/gimple-fold.c:1200
0x9763c9 fold_marked_statements
    ../../gcc-trunk/gcc/tree-inline.c:4380
0x980ff6 tree_function_versioning(tree_node*, tree_node*, vec<ipa_replace_map*,
va_gc, vl_embed>*, bool, bitmap_head_def*, bool, bitmap_head_def*,
basic_block_def*)
    ../../gcc-trunk/gcc/tree-inline.c:5354
0xd85e62 save_inline_function_body
    ../../gcc-trunk/gcc/ipa-inline-transform.c:368
0xd85e62 inline_transform(cgraph_node*)
    ../../gcc-trunk/gcc/ipa-inline-transform.c:425
0x880e6f execute_one_ipa_transform_pass
    ../../gcc-trunk/gcc/passes.c:2039
0x880e6f execute_all_ipa_transforms()
    ../../gcc-trunk/gcc/passes.c:2079
0x636160 expand_function
    ../../gcc-trunk/gcc/cgraphunit.c:1702
0x63809d expand_all_functions
    ../../gcc-trunk/gcc/cgraphunit.c:1814
0x63809d compile()
    ../../gcc-trunk/gcc/cgraphunit.c:2151
0x638729 finalize_compilation_unit()
    ../../gcc-trunk/gcc/cgraphunit.c:2228
0x516813 c_write_global_declarations()
    ../../gcc-trunk/gcc/c/c-decl.c:10125
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.
$ gcc-4.8 -O1 -c small.c
small.c: In function ‘foo’:
small.c:7:6: internal compiler error: Floating point exception
 void foo ()
      ^
0x7b925f crash_signal
    ../../gcc-4.8.1/gcc/toplev.c:332
0x678f55 fold_array_ctor_reference
    ../../gcc-4.8.1/gcc/gimple-fold.c:2819
0x678f55 fold_ctor_reference
    ../../gcc-4.8.1/gcc/gimple-fold.c:2967
0x67bd77 fold_const_aggregate_ref_1(tree_node*, tree_node* (*)(tree_node*))
    ../../gcc-4.8.1/gcc/gimple-fold.c:3069
0x67cd43 fold_const_aggregate_ref
    ../../gcc-4.8.1/gcc/gimple-fold.c:3091
0x67cd43 maybe_fold_reference
    ../../gcc-4.8.1/gcc/gimple-fold.c:277
0x67d434 gimple_fold_call
    ../../gcc-4.8.1/gcc/gimple-fold.c:1096
0x67d434 fold_stmt_1
    ../../gcc-4.8.1/gcc/gimple-fold.c:1202
0x7ee097 fold_marked_statements
    ../../gcc-4.8.1/gcc/tree-inline.c:4237
0x7f42b6 tree_function_versioning(tree_node*, tree_node*, vec<ipa_replace_map*,
va_gc, vl_embed>*, bool, bitmap_head_def*, bool, bitmap_head_def*,
basic_block_def*)
    ../../gcc-4.8.1/gcc/tree-inline.c:5299
0xb3d7c2 save_inline_function_body
    ../../gcc-4.8.1/gcc/ipa-inline-transform.c:351
0xb3d7c2 inline_transform(cgraph_node*)
    ../../gcc-4.8.1/gcc/ipa-inline-transform.c:408
0x7319c7 execute_one_ipa_transform_pass
    ../../gcc-4.8.1/gcc/passes.c:2172
0x7319c7 execute_all_ipa_transforms()
    ../../gcc-4.8.1/gcc/passes.c:2208
0x59f876 expand_function
    ../../gcc-4.8.1/gcc/cgraphunit.c:1633
0x5a0d06 expand_all_functions
    ../../gcc-4.8.1/gcc/cgraphunit.c:1744
0x5a0d06 compile()
    ../../gcc-4.8.1/gcc/cgraphunit.c:2042
0x5a10b9 finalize_compilation_unit()
    ../../gcc-4.8.1/gcc/cgraphunit.c:2119
0x4e0453 c_write_global_declarations()
    ../../gcc-4.8.1/gcc/c/c-decl.c:10118
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.
$ 


---------------------------------------


struct U {};

static struct U a[1] = {};

extern void bar(struct U); 

void foo ()
{
  bar (a[0]);
}

int main ()
{
  foo(); 
  return 0;
}
>From gcc-bugs-return-429178-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sat Sep 07 04:31:29 2013
Return-Path: <gcc-bugs-return-429178-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 29233 invoked by alias); 7 Sep 2013 04:31:28 -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 23920 invoked by uid 48); 7 Sep 2013 04:31:24 -0000
From: "su at cs dot ucdavis.edu" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug ipa/58346] New: ICE with SIGFPE at -O1 and above on x86_64-linux-gnu (affecting trunk, 4.8, 4.7, and 4.6)
Date: Sat, 07 Sep 2013 04:31:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: ipa
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: su at cs dot ucdavis.edu
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter
Message-ID: <bug-58346-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2013-09/txt/msg00418.txt.bz2
Content-length: 3502

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

            Bug ID: 58346
           Summary: ICE with SIGFPE at -O1 and above on x86_64-linux-gnu
                    (affecting trunk, 4.8, 4.7, and 4.6)
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: ipa
          Assignee: unassigned at gcc dot gnu.org
          Reporter: su at cs dot ucdavis.edu

The following code causes an ICE when compiled with the current gcc trunk, 4.8,
and 4.7 at -O1 and above (at only -O1 for 4.6) on x86_64-linux (both 32-bit and
64-bit modes). 

This should be related to 58345 (the backtraces are almost identical), but
affects also 4.6 and 4.7 as well as more optimization levels. 


$ gcc-trunk -v
Using built-in specs.
COLLECT_GCC=gcc-trunk
COLLECT_LTO_WRAPPER=/usr/local/gcc-trunk/libexec/gcc/x86_64-unknown-linux-gnu/4.9.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-trunk/configure
--enable-languages=c,c++,objc,obj-c++,fortran,lto
--with-gmp=/usr/local/gcc-trunk --with-mpfr=/usr/local/gcc-trunk
--with-mpc=/usr/local/gcc-trunk --with-cloog=/usr/local/gcc-trunk
--prefix=/usr/local/gcc-trunk
Thread model: posix
gcc version 4.9.0 20130906 (experimental) [trunk revision 202308] (GCC) 
$ gcc-trunk -O0 -c small.c
$ gcc-trunk -O1 -c small.c
small.c: In function ‘main’:
small.c:20:5: internal compiler error: Floating point exception
 int main ()
     ^
0x924b2f crash_signal
    ../../gcc-trunk/gcc/toplev.c:335
0x77ecd3 fold_array_ctor_reference
    ../../gcc-trunk/gcc/gimple-fold.c:2816
0x77ecd3 fold_ctor_reference
    ../../gcc-trunk/gcc/gimple-fold.c:2964
0x7827d2 fold_const_aggregate_ref_1(tree_node*, tree_node* (*)(tree_node*))
    ../../gcc-trunk/gcc/gimple-fold.c:3066
0x78443b fold_const_aggregate_ref
    ../../gcc-trunk/gcc/gimple-fold.c:3088
0x78443b maybe_fold_reference
    ../../gcc-trunk/gcc/gimple-fold.c:272
0x784df6 gimple_fold_call
    ../../gcc-trunk/gcc/gimple-fold.c:1091
0x784df6 fold_stmt_1
    ../../gcc-trunk/gcc/gimple-fold.c:1200
0x9763c9 fold_marked_statements
    ../../gcc-trunk/gcc/tree-inline.c:4380
0x983404 optimize_inline_calls(tree_node*)
    ../../gcc-trunk/gcc/tree-inline.c:4475
0xd85fa3 inline_transform(cgraph_node*)
    ../../gcc-trunk/gcc/ipa-inline-transform.c:436
0x880e6f execute_one_ipa_transform_pass
    ../../gcc-trunk/gcc/passes.c:2039
0x880e6f execute_all_ipa_transforms()
    ../../gcc-trunk/gcc/passes.c:2079
0x636160 expand_function
    ../../gcc-trunk/gcc/cgraphunit.c:1702
0x63809d expand_all_functions
    ../../gcc-trunk/gcc/cgraphunit.c:1814
0x63809d compile()
    ../../gcc-trunk/gcc/cgraphunit.c:2151
0x638729 finalize_compilation_unit()
    ../../gcc-trunk/gcc/cgraphunit.c:2228
0x516813 c_write_global_declarations()
    ../../gcc-trunk/gcc/c/c-decl.c:10125
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.
$ 


-----------------------------------------


struct U {};
static struct U b[1] = { };

int a, **c, d, *e, f;

extern void bar (int, int, int, struct U); 
extern void foobar (int, int, int); 
extern int baz (int, int); 

static void foo ()
{
  bar (d, 0, 0, b[0]);
  foobar (0 >= f, 0, 0);
  **c = 0 == a;
  baz (**c, 0);
  baz (0, *e);
  *e = baz (0, 0);
}

int main ()
{
  foo ();
  return 0;
}
>From gcc-bugs-return-429179-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sat Sep 07 06:35:30 2013
Return-Path: <gcc-bugs-return-429179-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 22306 invoked by alias); 7 Sep 2013 06:35:30 -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 22277 invoked by uid 48); 7 Sep 2013 06:35:26 -0000
From: "glisse at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug bootstrap/58340] [4.9 regression] gcc/cp/pt.c:7064:1: internal compiler error: in propagate_threaded_block_debug_into, at tree-ssa-threadedge.c:623
Date: Sat, 07 Sep 2013 06:35:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: bootstrap
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: glisse at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-58340-4-tneKIVE9qA@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-58340-4@http.gcc.gnu.org/bugzilla/>
References: <bug-58340-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2013-09/txt/msg00419.txt.bz2
Content-length: 408

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

--- Comment #5 from Marc Glisse <glisse at gcc dot gnu.org> ---
(In reply to Jeffrey A. Law from comment #3)
> Just to be sure, what version of the trunk are both of you using?

202346 for me. Configured with --prefix=... --with-system-zlib --disable-nls
--enable-libstdcxx-time=yes --disable-libvtv, built with make -j 6, on an
up-to-date debian testing.


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

* [Bug tree-optimization/58343] [4.9 Regression] ICE in dfs_enumerate_from, at cfganal.c:1036
  2013-09-07  3:46 [Bug tree-optimization/58343] New: ICE in dfs_enumerate_from, at cfganal.c:1036 su at cs dot ucdavis.edu
@ 2013-09-09  8:40 ` rguenth at gcc dot gnu.org
  2013-09-09 20:13 ` law at redhat dot com
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2013-09-09  8:40 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2013-09-09
                 CC|                            |law at gcc dot gnu.org
            Version|unknown                     |4.9.0
   Target Milestone|---                         |4.9.0
            Summary|ICE in dfs_enumerate_from,  |[4.9 Regression] ICE in
                   |at cfganal.c:1036           |dfs_enumerate_from, at
                   |                            |cfganal.c:1036
     Ever confirmed|0                           |1

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
Confirmed.


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

* [Bug tree-optimization/58343] [4.9 Regression] ICE in dfs_enumerate_from, at cfganal.c:1036
  2013-09-07  3:46 [Bug tree-optimization/58343] New: ICE in dfs_enumerate_from, at cfganal.c:1036 su at cs dot ucdavis.edu
  2013-09-09  8:40 ` [Bug tree-optimization/58343] [4.9 Regression] " rguenth at gcc dot gnu.org
@ 2013-09-09 20:13 ` law at redhat dot com
  2013-09-10  5:31 ` su at cs dot ucdavis.edu
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: law at redhat dot com @ 2013-09-09 20:13 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Jeffrey A. Law <law at redhat dot com> ---
Zhendong,

Thanks for the testcase.  What's happening here is the code to allow threading
through a simple forwarder block exposes an opportunity to build a
significantly deeper jump threading path than was possible in the past.

In the middle of that path is a loop header.  We attempt to thread through the
loop header to a point in the middle of the loop.  This is generally considered
a bad idea (creates irreducible regions among other things) and the jump
threading code attempts to prune these kind of jump threading requests.

However, due to limitations in how these undesirable cases are detected, it was
missed.  And the shape of the CFG was such that the code to handle jump threads
though loop headers would fail catastrophically.

I've got a fix for this in testing.


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

* [Bug tree-optimization/58343] [4.9 Regression] ICE in dfs_enumerate_from, at cfganal.c:1036
  2013-09-07  3:46 [Bug tree-optimization/58343] New: ICE in dfs_enumerate_from, at cfganal.c:1036 su at cs dot ucdavis.edu
  2013-09-09  8:40 ` [Bug tree-optimization/58343] [4.9 Regression] " rguenth at gcc dot gnu.org
  2013-09-09 20:13 ` law at redhat dot com
@ 2013-09-10  5:31 ` su at cs dot ucdavis.edu
  2013-09-10 12:30 ` law at gcc dot gnu.org
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: su at cs dot ucdavis.edu @ 2013-09-10  5:31 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from Zhendong Su <su at cs dot ucdavis.edu> ---
(In reply to Jeffrey A. Law from comment #2)

...  

> I've got a fix for this in testing.

Jeff, thanks very much for your explanation and quick fix.


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

* [Bug tree-optimization/58343] [4.9 Regression] ICE in dfs_enumerate_from, at cfganal.c:1036
  2013-09-07  3:46 [Bug tree-optimization/58343] New: ICE in dfs_enumerate_from, at cfganal.c:1036 su at cs dot ucdavis.edu
                   ` (2 preceding siblings ...)
  2013-09-10  5:31 ` su at cs dot ucdavis.edu
@ 2013-09-10 12:30 ` law at gcc dot gnu.org
  2013-09-10 12:37 ` law at redhat dot com
  2013-09-10 12:45 ` markus at trippelsdorf dot de
  5 siblings, 0 replies; 7+ messages in thread
From: law at gcc dot gnu.org @ 2013-09-10 12:30 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Jeffrey A. Law <law at gcc dot gnu.org> ---
Author: law
Date: Tue Sep 10 12:29:58 2013
New Revision: 202441

URL: http://gcc.gnu.org/viewcvs?rev=202441&root=gcc&view=rev
Log:
    PR tree-optimization/58343
    * tree-ssa-threadupdate.c (thread_block): Identify and disable
    jump threading requests through loop headers buried in the middle
    of a jump threading path.

    * tree-ssa-threadedge.c (thread_around_empty_blocks): Fix thinko
    in return value/type.

    * gcc.c-torture/compile/pr58343.c: New test.

Added:
    trunk/gcc/testsuite/gcc.c-torture/compile/pr58343.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree-ssa-threadedge.c
    trunk/gcc/tree-ssa-threadupdate.c


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

* [Bug tree-optimization/58343] [4.9 Regression] ICE in dfs_enumerate_from, at cfganal.c:1036
  2013-09-07  3:46 [Bug tree-optimization/58343] New: ICE in dfs_enumerate_from, at cfganal.c:1036 su at cs dot ucdavis.edu
                   ` (3 preceding siblings ...)
  2013-09-10 12:30 ` law at gcc dot gnu.org
@ 2013-09-10 12:37 ` law at redhat dot com
  2013-09-10 12:45 ` markus at trippelsdorf dot de
  5 siblings, 0 replies; 7+ messages in thread
From: law at redhat dot com @ 2013-09-10 12:37 UTC (permalink / raw)
  To: gcc-bugs

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

Jeffrey A. Law <law at redhat dot com> changed:

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

--- Comment #5 from Jeffrey A. Law <law at redhat dot com> ---
Fixed on trunk.


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

* [Bug tree-optimization/58343] [4.9 Regression] ICE in dfs_enumerate_from, at cfganal.c:1036
  2013-09-07  3:46 [Bug tree-optimization/58343] New: ICE in dfs_enumerate_from, at cfganal.c:1036 su at cs dot ucdavis.edu
                   ` (4 preceding siblings ...)
  2013-09-10 12:37 ` law at redhat dot com
@ 2013-09-10 12:45 ` markus at trippelsdorf dot de
  5 siblings, 0 replies; 7+ messages in thread
From: markus at trippelsdorf dot de @ 2013-09-10 12:45 UTC (permalink / raw)
  To: gcc-bugs

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

Markus Trippelsdorf <markus at trippelsdorf dot de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |markus at trippelsdorf dot de

--- Comment #6 from Markus Trippelsdorf <markus at trippelsdorf dot de> ---
*** Bug 58373 has been marked as a duplicate of this bug. ***


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

end of thread, other threads:[~2013-09-10 12:45 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-07  3:46 [Bug tree-optimization/58343] New: ICE in dfs_enumerate_from, at cfganal.c:1036 su at cs dot ucdavis.edu
2013-09-09  8:40 ` [Bug tree-optimization/58343] [4.9 Regression] " rguenth at gcc dot gnu.org
2013-09-09 20:13 ` law at redhat dot com
2013-09-10  5:31 ` su at cs dot ucdavis.edu
2013-09-10 12:30 ` law at gcc dot gnu.org
2013-09-10 12:37 ` law at redhat dot com
2013-09-10 12:45 ` markus at trippelsdorf dot de

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