[regehr@gamow tmp407]$ current-gcc -c -O3 small.c small.c: In function 'int161': small.c:19:1: internal compiler error: in vect_create_epilog_for_reduction, at tree-vect-loop.c:3451 Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions. [regehr@gamow tmp407]$ current-gcc -v Using built-in specs. COLLECT_GCC=current-gcc COLLECT_LTO_WRAPPER=/uusoc/exports/scratch/regehr/z/compiler-install/gcc-r158618-install/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.6.0/lto-wrapper Target: x86_64-unknown-linux-gnu Configured with: ../configure --with-libelf=/usr/local --enable-lto --prefix=/home/regehr/z/compiler-install/gcc-r158618-install --program-prefix=r158618- --enable-languages=c,c++ Thread model: posix gcc version 4.6.0 20100421 (experimental) (GCC) [regehr@gamow tmp407]$ cat small.c typedef short int int16_t; typedef int int32_t; typedef unsigned short int uint16_t; typedef unsigned int uint32_t; static int16_t safe_rshift_func_int16_t_s_u (int16_t left, unsigned int right) { return left || right >= 1 * 8 ? left : left >> right; } static uint32_t safe_add_func_uint32_t_u_u (uint32_t ui1, uint16_t ui2) { return ui1 + ui2; } int16_t g_4; uint32_t g_9[1]; int161 (void) { int32_t l_2; for (l_2 = -25; l_2; l_2 = safe_add_func_uint32_t_u_u (l_2, 1)) g_9[0] ^= safe_rshift_func_int16_t_s_u (g_4, 1); return 0; }
Confirmed.
It is caused by revision 158506: http://gcc.gnu.org/ml/gcc-cvs/2010-04/msg00612.html
I think revision 158650: http://gcc.gnu.org/ml/gcc-cvs/2010-04/msg00756.html is the fix for this bug.
Subject: Bug 43842 Author: irar Revision: 158650 Modified property: svn:log Modified: svn:log at Thu Apr 22 18:22:54 2010 ------------------------------------------------------------------------------ --- svn:log (original) +++ svn:log Thu Apr 22 18:22:54 2010 @@ -1,5 +1,5 @@ - PR tree-optimization/43482 + PR tree-optimization/43842 * tree-vect-loop.c (vect_create_epilog_for_reduction): Handle loop unrolling in update of exit phis. Fix comment. * tree-vect-slp.c (vect_analyze_slp): Check that there are at
Fixed.