[Bug c++/43024] New: ICE on template code with -O2 or -O3, regression from 4.4.2

orzel at freehackers dot org gcc-bugzilla@gcc.gnu.org
Wed Feb 10 19:32:00 GMT 2010


Upgrading from 4.4.2 to 4.4.3, gcc now segfaults when compiling my file. I've
narrowed both the command line and the cpp file (30 lines, visible at the end
of the *.ii attached). Most of the included code is from eigen
(http://eigen.tuxfamily.org/) and is publicly visible on 
http://bitbucket.org/eigen/eigen

When compiled with -O2 or -O3 the segfaults is triggered, without -O option,
the file compiles fine.

The complete line i use is:
g++ -c -O3 -I../../eigen2-tip -o ice.o ice.cpp -save-temps

The output is:
----------------------------------------------------------------------------
In file included from ../../eigen2-tip/Eigen/Core:178,
                 from
../../eigen2-tip/unsupported/Eigen/NonLinearOptimization:29,
                 from ice.cpp:3:
../../eigen2-tip/Eigen/src/Core/DenseStorageBase.h: In member function
‘Eigen::LevenbergMarquardtSpace::Status Eigen::LevenbergMarquardt<FunctorType,
Scalar>::minimizeOneStep(Eigen::Matrix<Scalar, 33331, 1, 0, 33331, 1>&, int)
[with FunctorType = myFunctor, Scalar = double]Â’:            
../../eigen2-tip/Eigen/src/Core/DenseStorageBase.h:516: internal compiler
error: Segmentation fault
Please submit a full bug report, with preprocessed source if appropriate.
See <http://bugs.gentoo.org/> for instructions.  
----------------------------------------------------------------------------

The output of gcc -v is (i'm using gentoo) :
----------------------------------------------------------------------------
Using built-in specs.
Target: x86_64-pc-linux-gnu
Configured with:
/usr/data/tmp/portage/sys-devel/gcc-4.4.3/work/gcc-4.4.3/configure
--prefix=/usr --bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/4.4.3
--includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.3/include
--datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.3
--mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.3/man
--infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/4.4.3/info
--with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.3/include/g++-v4
--host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --disable-altivec
--disable-fixed-point --without-ppl --without-cloog --enable-nls
--without-included-gettext --with-system-zlib --disable-checking
--disable-werror --enable-secureplt --enable-multilib --enable-libmudflap
--disable-libssp --enable-libgomp --enable-cld
--with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/4.4.3/python
--disable-libgcj --enable-languages=c,c++ --enable-shared
--enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu
--with-bugurl=http://bugs.gentoo.org/ --with-pkgversion='Gentoo 4.4.3 p1.0'
Thread model: posix
gcc version 4.4.3 (Gentoo 4.4.3 p1.0)
----------------------------------------------------------------------------


-- 
           Summary: ICE on template code with -O2 or -O3, regression from
                    4.4.2
           Product: gcc
           Version: 4.4.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: orzel at freehackers dot org
  GCC host triplet: x86_64-pc-linux-gnu
GCC target triplet: x86_64-pc-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43024



More information about the Gcc-bugs mailing list