This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/82742] New: ICE on valid code at -O3: verify_flow_info failed
- From: "su at cs dot ucdavis.edu" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 27 Oct 2017 05:56:02 +0000
- Subject: [Bug middle-end/82742] New: ICE on valid code at -O3: verify_flow_info failed
- Auto-submitted: auto-generated
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82742
Bug ID: 82742
Summary: ICE on valid code at -O3: verify_flow_info failed
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: middle-end
Assignee: unassigned at gcc dot gnu.org
Reporter: su at cs dot ucdavis.edu
Target Milestone: ---
This seems to be a recent regression.
$ gcctk -v
Using built-in specs.
COLLECT_GCC=gcctk
COLLECT_LTO_WRAPPER=/home/su/software/tmp/gcc/gcc-trunk/libexec/gcc/x86_64-pc-linux-gnu/8.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../gcc-source-trunk/configure --enable-languages=c,c++,lto
--prefix=/home/su/software/tmp/gcc/gcc-trunk --disable-bootstrap
Thread model: posix
gcc version 8.0.0 20171026 (experimental) [trunk revision 254125] (GCC)
$
$ gcctk -O2 small.c; ./a.out
$ gcc-7.2.0 -O3 small.c; ./a.out
$
$ gcctk -O3 small.c
small.c: In function ‘i’:
small.c:31:1: error: non-cold basic block 18 reachable only by paths crossing
the cold partition
}
^
during RTL pass: bbro
small.c:31:1: internal compiler error: verify_flow_info failed
0x7f53e6 verify_flow_info()
../../gcc-source-trunk/gcc/cfghooks.c:263
0x80d104 checking_verify_flow_info
../../gcc-source-trunk/gcc/cfghooks.h:198
0x80d104 cfg_layout_finalize()
../../gcc-source-trunk/gcc/cfgrtl.c:4304
0x13788c9 execute
../../gcc-source-trunk/gcc/bb-reorder.c:2601
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
$
------------------------------------------
int a, b, c, d;
static int e = 1;
void i (int);
char f (unsigned char g, int h)
{
return g > (255 >> h) ? 0 : h;
}
void j (int g, int h)
{
d = 0;
}
int k (int g)
{
i (g);
return a;
}
void i (int g)
{
while (1)
{
if (!b)
break;
while (c)
j (k (f (d, g && e)), d);
}
}
int main ()
{
i (0);
return 0;
}