[forwarded from http://bugs.debian.org/320178]

ICE's with 3.4 CVS 20051015, works with 3.3.6, 4.0.2, 4.1.0.

  Matthias

$ cat was_inifcns_nstdsums.cpp

#include <cln/cln.h>
#include <ginac/numeric.h>

namespace GiNaC {
                numeric was_Lin_numeric(int n, const numeric& x)
                {
                                numeric moo = -cln::log(1-x.to_cl_N());
                                numeric foo = cln::zeta(n);
                          numeric bar = -(1-cln::expt(cln::cl_I(2),1-n)) *
cln::zeta(n);

                                cln::cl_N x_ = ex_to<numeric>(x).to_cl_N();
                                cln::cl_N result = -cln::expt(cln::log(x_),
n-1) * cln::log(1-x_) / cln::factorial(n-1);
                                numeric num2_(2, 5);
                                int j = 5;
                                result = result +
num2_.to_cl_N()*cln::expt(cln::log(x_), j) / cln::factorial(j);
                                result = result +
num2_.to_cl_N()*cln::expt(cln::log(x_), j) / cln::factorial(j);

                                return result;
                }
}

$ g++-3.4 -save-temps -fPIC -DPIC -O -g -c was_inifcns_nstdsums.cpp
/usr/include/cln/float.h: In function `const cln::cl_R cln::operator*(const
cln::cl_RA&, const cln::cl_F&)':
/usr/include/cln/float.h:235: internal compiler error: in gen_subprogram_die,
at dwarf2out.c:10881
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
For Debian GNU/Linux specific bug reporting instructions,
see <URL:file:///usr/share/doc/gcc-3.4/README.Bugs>.

Header files <cln/cln.h> and <ginac/numeric.h> can be found in the
packages libcln-dev and libginac-dev, respectively.

Note that

1) compiler flags "-O -g" are essential, e.g. everything compiles
   fine with "-O2 -g". 
2) both g++-3.3 and g++-4.0 have no such a problem.

Pre-processed code (bzip2 compressed) is attached.

Best regards,
  Alexei


-- 
           Summary: [3.4 regression] ICE in gen_subprogram_die, at
                    dwarf2out.c
           Product: gcc
           Version: 3.4.4
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: debian-gcc at lists dot debian dot org


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

Reply via email to