https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77514
Bug ID: 77514
Summary: [7 Regression] ICE in VN_INFO_GET, at
tree-ssa-sccvn.c:406 w/ -O2 (and above)
Product: gcc
Version: 7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: asolokha at gmx dot com
Target Milestone: ---
gcc-7.0.0-alpha20160904 ICEs when compiling the following reduces snippet at
-O2 (-O3, -Ofast):
void
m1 (char l0, char e8, int hw)
{
char *rs = &l0;
yu:
l0 = 1;
while (l0 != 0)
{
l0 = -l0;
l0 += (*rs ^ (l0 &= 1));
}
for (;;)
{
if (hw != 0)
goto yu;
rs = &e8;
}
}
% gcc-7.0.0-alpha20160904 -O2 -c nhbgsfda.c -Wall -Wextra -Wpedantic
nhbgsfda.c: In function 'm1':
nhbgsfda.c:11:10: warning: operation on 'l0' may be undefined
[-Wsequence-point]
l0 += (*rs ^ (l0 &= 1));
^~
nhbgsfda.c:2:1: internal compiler error: in VN_INFO_GET, at
tree-ssa-sccvn.c:406
m1 (char l0, char e8, int hw)
^~