This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/68520] New: ICE on valid code at -O3 on x86_64-linux-gnu in quick_push, at vec.h:845
- 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: Tue, 24 Nov 2015 14:18:26 +0000
- Subject: [Bug target/68520] New: ICE on valid code at -O3 on x86_64-linux-gnu in quick_push, at vec.h:845
- Auto-submitted: auto-generated
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68520
Bug ID: 68520
Summary: ICE on valid code at -O3 on x86_64-linux-gnu in
quick_push, at vec.h:845
Product: gcc
Version: 6.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: target
Assignee: unassigned at gcc dot gnu.org
Reporter: su at cs dot ucdavis.edu
Target Milestone: ---
The following code causes an ICE when compiled with the current gcc trunk at
-O3 on x86_64-linux-gnu in both 32-bit and 64-bit modes.
It is a regression from 5.2.x.
$ gcc-trunk -v
Using built-in specs.
COLLECT_GCC=gcc-trunk
COLLECT_LTO_WRAPPER=/usr/local/gcc-trunk/libexec/gcc/x86_64-pc-linux-gnu/6.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../gcc-trunk/configure --prefix=/usr/local/gcc-trunk
--enable-languages=c,c++ --disable-werror --enable-multilib
Thread model: posix
gcc version 6.0.0 20151122 (experimental) [trunk revision 230719] (GCC)
$
$ gcc-trunk -O2 -c small.c
$ gcc-5.2 -O3 -c small.c
$
$ gcc-trunk -O3 -c small.c
small.c: In function âfn2â:
small.c:10:1: internal compiler error: in quick_push, at vec.h:845
}
^
0xac60d2 vec<basic_block_def*, va_heap, vl_embed>::quick_push(basic_block_def*
const&)
../../gcc-trunk/gcc/vec.h:845
0xac60d2 vec<basic_block_def*, va_heap, vl_ptr>::quick_push(basic_block_def*
const&)
../../gcc-trunk/gcc/vec.h:1503
0xac60d2 try_shrink_wrapping(edge_def**, bitmap_head*, rtx_insn*)
../../gcc-trunk/gcc/shrink-wrap.c:714
0x870058 thread_prologue_and_epilogue_insns()
../../gcc-trunk/gcc/function.c:6021
0x870a92 rest_of_handle_thread_prologue_and_epilogue
../../gcc-trunk/gcc/function.c:6543
0x870a92 execute
../../gcc-trunk/gcc/function.c:6585
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, b, c, d;
void
fn2 ()
{
if (c)
for (; d; d = a+b)
for (c = 0; c < 2; c++)
fn2 ();
}