https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61224
Bug ID: 61224
Summary: ICE in rtl.h
Product: gcc
Version: 4.10.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: ishiura-compiler at ml dot kwansei.ac.jp
GCC 4.10.0 ICEs on the following code. (x86_64)
$ cat test.c
int a, b, d;
int main (void)
{
int c = a && 1;
d = 1 << (((c | (b - 842)) << 1) + 1);
return 0;
}
$ x86_64-unknown-linux-gnu-gcc-4.10.0 test.c -O2
test.c: In function 'main':
test.c:8:1: internal compiler error: in decompose, at rtl.h:1456
}
^
0x4f1296 wi::int_traits<std::pair<rtx_def*, machine_mode> >::decompose(long*,
unsigned int, std::pair<rtx_def*, machine_mode> const&)
/home/hassy/gcc/gcc/rtl.h:1454
0x9ac619 wi::int_traits<std::pair<rtx_def*, machine_mode> >::decompose(long*,
unsigned int, std::pair<rtx_def*, machine_mode> const&)
/home/hassy/gcc/gcc/rtl.h:1454
0x9ac619 wide_int_ref_storage<std::pair<rtx_def*, machine_mode> >
/home/hassy/gcc/gcc/wide-int.h:959
0x9ac619 generic_wide_int<std::pair<rtx_def*, machine_mode> >
/home/hassy/gcc/gcc/wide-int.h:735
0x9ac619 sub<std::pair<rtx_def*, machine_mode>, std::pair<rtx_def*,
machine_mode> >
/home/hassy/gcc/gcc/wide-int.h:2349
0x9ac619 simplify_const_binary_operation(rtx_code, machine_mode, rtx_def*,
rtx_def*)
/home/hassy/gcc/gcc/simplify-rtx.c:3732
0xe7153b simplify_shift_const_1
/home/hassy/gcc/gcc/combine.c:10352
0xe71875 simplify_shift_const
/home/hassy/gcc/gcc/combine.c:10526
0xe798cd combine_simplify_rtx
/home/hassy/gcc/gcc/combine.c:5873
0xe7bcda subst
/home/hassy/gcc/gcc/combine.c:5170
0xe794fb combine_simplify_rtx
/home/hassy/gcc/gcc/combine.c:5250
0xe7bcda subst
/home/hassy/gcc/gcc/combine.c:5170
0xe7b9f8 subst
/home/hassy/gcc/gcc/combine.c:5115
0xe7b9f8 subst
/home/hassy/gcc/gcc/combine.c:5115
0xe7b9f8 subst
/home/hassy/gcc/gcc/combine.c:5115
0xe7b82a subst
/home/hassy/gcc/gcc/combine.c:5036
0xe7cfce try_combine
/home/hassy/gcc/gcc/combine.c:3138
0xe82d03 combine_instructions
/home/hassy/gcc/gcc/combine.c:1370
0xe82d03 rest_of_handle_combine
/home/hassy/gcc/gcc/combine.c:13865
0xe82d03 execute
/home/hassy/gcc/gcc/combine.c:13909
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.
$ x86_64-unknown-linux-gnu-gcc-4.10.0 -v
Using built-in specs.
COLLECT_GCC=x86_64-unknown-linux-gnu-gcc-4.10.0
COLLECT_LTO_WRAPPER=/usr/local/x86_64-tools/gcc-4.10.0/libexec/gcc/x86_64-unknown-linux-gnu/4.10.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: /home/hassy/gcc/configure
--prefix=/usr/local/x86_64-tools/gcc-4.10.0/ --with-gmp=/usr/local/gmp-5.1.1/
--with-mpfr=/usr/local/mpfr-3.1.2/ --with-mpc=/usr/local/mpc-1.0.1/
--disable-multilib --disable-nls --enable-languages=c
Thread model: posix
gcc version 4.10.0 20140518 (experimental) (GCC)