This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug middle-end/20995] New: [3.4 regression] ICE in const_binop, at fold-const.c:1391


This little piece of code here
-----------------
template <int dim>
void test ()
{
  double d;
  double mu = 1;
  for (unsigned int i=0; i<dim; ++i)
    for (unsigned int j=0; j<dim; ++j)
      for (unsigned int k=0; k<dim; ++k)
        for (unsigned int l=0; l<dim; ++l)
          d = (((i==k) && (j==l) ? mu : 0) +
               ((i==j) && (k==l) ? 1 : 0));
}
template void test<3> ();
-----------------
ICEs with gcc3.4.4pre (and apparently all older versions of the 3.4.x branch I
have):

deal.II/tests> /ices/bangerth/tmp/build-gcc-3.4/gcc-install/bin/c++ -c x.cc
x.cc: In function `void test()':
x.cc:11: internal compiler error: tree check: expected real_cst, have
integer_cst in const_binop, at fold-const.c:1391
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.

On the machine I'm on right now, I don't have a 4.x compiler, so it may even be
a regression on 4.0 branch and/or mainline. It doesn't ICE gcc3.3.x, though.

W.

-- 
           Summary: [3.4 regression] ICE in const_binop, at fold-
                    const.c:1391
           Product: gcc
           Version: 3.4.4
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P2
         Component: middle-end
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: bangerth at dealii dot org
                CC: gcc-bugs at gcc dot gnu dot org


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]