Bug 28888 - [4.1 regression] ICE in tree check: expected cond_expr, have label_expr in simplify_using_initial_conditions, at tree-ssa-loop-niter.c
Summary: [4.1 regression] ICE in tree check: expected cond_expr, have label_expr in si...
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: tree-optimization (show other bugs)
Version: 4.1.1
: P1 normal
Target Milestone: 4.1.2
Assignee: Zdenek Dvorak
URL: http://gcc.gnu.org/ml/gcc-patches/200...
Keywords: patch
Depends on:
Blocks:
 
Reported: 2006-08-29 15:10 UTC by Martin Michlmayr
Modified: 2006-11-19 16:11 UTC (History)
6 users (show)

See Also:
Host:
Target:
Build:
Known to work: 4.2.0
Known to fail:
Last reconfirmed: 2006-08-29 20:33:28


Attachments
test case (226 bytes, text/plain)
2006-08-29 15:11 UTC, Martin Michlmayr
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Michlmayr 2006-08-29 15:10:47 UTC
I get a tree check error with -ftree-vectorize.  It works with 4.0 but fails with 4.1 and 4.2.

(sid)345:tbm@usurper: ~] x86_64-unknown-linux-gnu-gcc -ftree-vectorize -Os -c oo2c-allocate.c
oo2c-allocate.c: In function 'Allocate__WriteStats':
oo2c-allocate.c:4: internal compiler error: tree check: expected cond_expr, have label_expr in simplify_using_initial_conditions, at tree-ssa-loop-niter.c:926
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
zsh: exit 1     x86_64-unknown-linux-gnu-gcc -ftree-vectorize -Os -c oo2c-allocate.c
(sid)346:tbm@usurper: ~] x86_64-unknown-linux-gnu-gcc -ftree-vectorize -O1 -c oo2c-allocate.c
oo2c-allocate.c: In function 'Allocate__WriteStats':
oo2c-allocate.c:4: internal compiler error: tree check: expected cond_expr, have modify_expr in simplify_using_initial_conditions, at tree-ssa-loop-niter.c:926
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
zsh: exit 1     x86_64-unknown-linux-gnu-gcc -ftree-vectorize -O1 -c oo2c-allocate.c
(sid)347:tbm@usurper: ~] x86_64-unknown-linux-gnu-gcc -ftree-vectorize -O2 -c oo2c-allocate.c
oo2c-allocate.c: In function 'Allocate__WriteStats':
oo2c-allocate.c:4: internal compiler error: tree check: expected cond_expr, have label_expr in simplify_using_initial_conditions, at tree-ssa-loop-niter.c:926
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
zsh: exit 1     x86_64-unknown-linux-gnu-gcc -ftree-vectorize -O2 -c oo2c-allocate.c
(sid)348:tbm@usurper: ~] x86_64-unknown-linux-gnu-gcc -ftree-vectorize -O3 -c oo2c-allocate.c
(sid)349:tbm@usurper: ~]
Comment 1 Martin Michlmayr 2006-08-29 15:11:32 UTC
Created attachment 12149 [details]
test case

Testcase from application "oo2c".
Comment 2 Zdenek Dvorak 2006-08-30 10:35:53 UTC
Patch: http://gcc.gnu.org/ml/gcc-patches/2006-08/msg01131.html
Comment 3 Zdenek Dvorak 2006-09-22 10:03:02 UTC
Subject: Bug 28888

Author: rakdver
Date: Fri Sep 22 10:02:47 2006
New Revision: 117135

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=117135
Log:
	PR tree-optimization/28888
	* tree-if-conv.c (combine_blocks): Rewritten.
	* tree-cfg.c (tree_verify_flow_info): Check that edges with
	EDGE_TRUE/FALSE_VALUE follow COND_EXPR.

	* gcc.dg/pr28888.c: New test.


Added:
    trunk/gcc/testsuite/gcc.dg/pr28888.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree-cfg.c
    trunk/gcc/tree-if-conv.c

Comment 4 Richard Biener 2006-11-19 16:09:32 UTC
Subject: Bug 28888

Author: rguenth
Date: Sun Nov 19 16:09:19 2006
New Revision: 118988

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=118988
Log:
2006-11-19  Richard Guenther  <rguenther@suse.de>

	Backport from mainline:
	2006-09-22  Zdenek Dvorak <dvorakz@suse.cz>

        PR tree-optimization/28888
        * tree-if-conv.c (combine_blocks): Rewritten.
        * tree-cfg.c (tree_verify_flow_info): Check that edges with
        EDGE_TRUE/FALSE_VALUE follow COND_EXPR.

        * gcc.dg/pr28888.c: New test.

Added:
    branches/gcc-4_1-branch/gcc/testsuite/gcc.dg/pr28888.c
      - copied unchanged from r117135, trunk/gcc/testsuite/gcc.dg/pr28888.c
Modified:
    branches/gcc-4_1-branch/gcc/ChangeLog
    branches/gcc-4_1-branch/gcc/testsuite/ChangeLog
    branches/gcc-4_1-branch/gcc/tree-cfg.c
    branches/gcc-4_1-branch/gcc/tree-if-conv.c

Comment 5 Richard Biener 2006-11-19 16:11:28 UTC
Fixed.