https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71478
Bug ID: 71478
Summary: ICE in tree-ssa-reassoc.c after r236564
Product: gcc
Version: 7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: jgreenhalgh at gcc dot gnu.org
CC: kugan.vivekanandarajah at linaro dot org
Target Milestone: ---
Created attachment 38671
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38671&action=edit
Reduced testcase
I took a look at PR71170, PR71230, PR71252 and PR 71281, but they seemed subtly
different to my issue.
The attached testcase fails for me on trunk with -O1 on
x86_x64-unknown-linux-gnu and aarch64-none-linux-gnu.
The ICE looks like:
x.c: In function 'foo':
x.c:7:1: internal compiler error: gimple check: expected
gimple_assign(error_mark), have gimple_call() in gimple_assign_rhs1, at
gimple.h:2493
foo (void)
^~~
0x856d7b gimple_check_failed(gimple const*, char const*, int, char const*,
gimple_code, tree_code)
.../gcc/gimple.c:1177
0xc92547 GIMPLE_CHECK2<const gassign*>
.../gcc/gimple.h:73
0xc92547 gimple_assign_rhs1
.../gcc/gimple.h:2493
0xc96d28 rewrite_expr_tree
.../gcc/tree-ssa-reassoc.c:3834
0xc97112 rewrite_expr_tree
.../gcc/tree-ssa-reassoc.c:3931
0xca1970 reassociate_bb
.../gcc/tree-ssa-reassoc.c:5372
0xca1c07 reassociate_bb
.../gcc/tree-ssa-reassoc.c:5414
0xca21c0 do_reassoc
.../gcc/tree-ssa-reassoc.c:5528
0xca21c0 execute_reassoc
.../gcc/tree-ssa-reassoc.c:5615
0xca21c0 execute
.../gcc/tree-ssa-reassoc.c:5654
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.