Created attachment 25245 [details] bzipped preprocessed cxx source hi all, attached preprocessed cxx source compilation failed with optimisation level 2 or higher [level 1 and 0 works fine]. mario. > g++ -m32 -O2 -c foo.ii foo.ii:114:123: warning: inline function 'uint32_t boost::interprocess::detail::atomic_cas32(volatile uint32_t*, uint32_t, uint32_t)' used but never defined [enabled by default] foo.ii:114:32: warning: inline function 'void boost::interprocess::detail::atomic_write32(volatile uint32_t*, uint32_t)' used but never defined [enabled by default] foo.ii: In function 'void foo()': foo.ii:120:7: error: type mismatch in pointer plus expression struct node_ptr & restrict struct node_ptr & sizetype pretmp.51_110 = &D.5627 + pretmp.49_111; foo.ii:120:7: error: type mismatch in pointer plus expression struct node_ptr & restrict struct node_ptr & sizetype pretmp.47_116 = &D.5662 + pretmp.45_117; foo.ii:120:7: internal compiler error: verify_gimple failed Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions. ========================= system-info ================================= > uname -a Linux ahsoka.intec.dom 2.6.32-131.12.1.el6.x86_64 #1 SMP Sun Jul 31 16:44:56 EDT 2011 x86_64 x86_64 x86_64 GNU/Linux > rpm -qa "glibc*" | grep -e 'glibc-[0-9]' | sort -u glibc-2.12-1.25.el6_1.3.i686 glibc-2.12-1.25.el6_1.3.x86_64 > g++ -v Using built-in specs. COLLECT_GCC=g++ COLLECT_LTO_WRAPPER=/app2/gcc/4.7.0-20110912-svn178775/x86_64/libexec/gcc/x86_64-unknown-linux-gnu/4.7.0/lto-wrapper Target: x86_64-unknown-linux-gnu Configured with: ./configure --prefix=/app2/gcc/4.7.0-20110912-svn178775/x86_64 --enable-languages=c,c++,fortran --disable-nls --with-gmp=/app2/gcc/4.7.0-20110912-svn178775/x86_64/aux --with-mpfr=/app2/gcc/4.7.0-20110912-svn178775/x86_64/aux --with-mpc=/app2/gcc/4.7.0-20110912-svn178775/x86_64/aux --with-ppl=/app2/gcc/4.7.0-20110912-svn178775/x86_64/aux --with-cloog=/app2/gcc/4.7.0-20110912-svn178775/x86_64/aux Thread model: posix gcc version 4.7.0 20110912 (experimental) (GCC) > ld -v GNU ld (GNU Binutils) 2.21.52.20110714
Created attachment 25252 [details] reduced testcase This testcase needs more flags to reproduce though: $ gcc -O2 -fno-tree-ch -fno-tree-fre testcase.c testcase.c: In function 'foo': testcase.c:2:1: error: type mismatch in pointer plus expression int * restrict int * long unsigned int pretmp.2_13 = p_3 + pretmp.1_12; testcase.c:2:1: internal compiler error: verify_gimple failed Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions.
I will have a look.
Author: rguenth Date: Tue Sep 27 08:53:08 2011 New Revision: 179247 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=179247 Log: 2011-09-27 Richard Guenther <rguenther@suse.de> PR tree-optimization/50363 * tree-ssa-pre.c (create_expression_by_pieces): Handle pointer conversions in POINTER_PLUS_EXPRs properly. * gcc.dg/torture/pr50363.c: New testcase. Added: trunk/gcc/testsuite/gcc.dg/torture/pr50363.c Modified: trunk/gcc/ChangeLog trunk/gcc/testsuite/ChangeLog trunk/gcc/tree-ssa-pre.c
Fixed.