ICE in dwarf2out.c, egcs-2.92.11 19980921
Peter Nordlund
petern@nada.kth.se
Sat Sep 26 06:06:00 GMT 1998
For a long time there has been problems with the Blitz++-package on
SGI Octane.
Internal error in dwarf2out.c has occurred when compiling the testsuite
with -g as long as I remember.
Now I have reduced the code to the following program.
I hope that someone understands what is causing the ICE.
------------------------------
marr:testsuite>>g++ -g err.cc
../../src/egcs-19980921/gcc/dwarf2out.c:7634: Internal compiler error in
function scope_die_for
marr:testsuite>>uname -a
IRIX64 marr 6.4 02121744 IP30 mips
marr:testsuite>>g++ -v
Reading specs from
/usr/local/cvap/egcs/egcs-19980921/lib/gcc-lib/mips-sgi-irix6.4/egcs-2.92.11/specs
gcc version egcs-2.92.11 19980921 (gcc2 ss-980609 experimental)
Due to a known bug in the last snapshot I patched the
egcs-19980921/gcc/Makefile.in in
the following manner: (I hope this was the right way to do it?)
diff /usr/local/cvap/egcs/src/egcs-19980921/gcc/Makefile.in
/usr/local/cvap/egcs/src/egcs-19980921/gcc/Makefile.in~
63,65c63,65
< XCFLAGS = -fno-weak
< TCFLAGS = -fno-weak
< CFLAGS = -fno-weak -g @stage1_warn_cflags@
---
> XCFLAGS =
> TCFLAGS =
> CFLAGS = -g @stage1_warn_cflags@
I have attached the ii-file in the mail.
(It doesn't look interesting to me.)
//Peter
//-----------------------------------------------------
// err.cc
template<int N_rank>
class GeneralArrayStorage {
public:
class noInitializeFlag { };
GeneralArrayStorage(noInitializeFlag) { }
GeneralArrayStorage(){}
};
template<int N_rank>
class FortranArray : public GeneralArrayStorage<N_rank> {
public:
FortranArray()
// Keep this line, otherwise it compiles
: GeneralArrayStorage<N_rank>(noInitializeFlag()){ }
};
template<class P_numtype, int N_rank>
class Array
{
public:
Array(int length0, int length1,
GeneralArrayStorage<N_rank> storage =
GeneralArrayStorage<N_rank>()) {}
};
int main()
{
Array<int,2> B(3,3); // Keep this line, otherwise it compiles
Array<int,2> D(3,3,FortranArray<2>());
return 0;
}
---------------------------------------------------------
Compilation output with -v:
marr:testsuite>>g++ -g -v -save-temps err.cc
Reading specs from
/usr/local/cvap/egcs/egcs-19980921/lib/gcc-lib/mips-sgi-irix6.4/egcs-2.92.11/specs
gcc version egcs-2.92.11 19980921 (gcc2 ss-980609 experimental)
/usr/local/cvap/egcs/egcs-19980921/lib/gcc-lib/mips-sgi-irix6.4/egcs-2.92.11/cpp
-lang-c++ -v -undef -D__GNUC__=2 -D__GNUG__=2 -D__cplusplus
-D__GNUC_MINOR__=92 -Dunix -Dmips -Dsgi -Dhost_mips -DMIPSEB -D_MIPSEB
-DSYSTYPE_SVR4 -D_LONGLONG -D_SVR4_SOURCE -D_MODERN_C -D__DSO__
-D__unix__ -D__mips__ -D__sgi__ -D__host_mips__ -D__MIPSEB__ -D_MIPSEB
-D__SYSTYPE_SVR4__ -D_LONGLONG -D_SVR4_SOURCE -D_MODERN_C -D__DSO__
-D__unix -D__mips -D__sgi -D__host_mips -D__MIPSEB -D__SYSTYPE_SVR4
-Asystem(unix) -Asystem(svr4) -Acpu(mips) -Amachine(sgi) -D__EXCEPTIONS
-D__CHAR_UNSIGNED__ -g -D__LANGUAGE_C_PLUS_PLUS -D_LANGUAGE_C_PLUS_PLUS
-D__SIZE_TYPE__=unsigned int -D__PTRDIFF_TYPE__=int -D__EXTENSIONS__
-D_SGI_SOURCE -D_MIPS_FPSET=32 -D_MIPS_ISA=_MIPS_ISA_MIPS3 -D_ABIN32=2
-D_MIPS_SIM=_ABIN32 -D_MIPS_SZINT=32 -D_MIPS_SZLONG=32 -D_MIPS_SZPTR=32
-D_COMPILER_VERSION=601 -U__mips -D__mips=3 -D__mips64 err.cc err.ii
GNU CPP version egcs-2.92.11 19980921 (gcc2 ss-980609 experimental) [AL
1.1, MM 40] SGI running IRIX 6.x
#include "..." search starts here:
#include <...> search starts here:
/usr/local/cvap/egcs/egcs-19980921/include/g++-2
/usr/local/cvap/egcs/egcs-19980921/mips-sgi-irix6.4/include
/usr/local/cvap/egcs/egcs-19980921/lib/gcc-lib/mips-sgi-irix6.4/egcs-2.92.11/include
/usr/include
End of search list.
/usr/local/cvap/egcs/egcs-19980921/lib/gcc-lib/mips-sgi-irix6.4/egcs-2.92.11/cc1plus
err.ii -quiet -dumpbase err.cc -g -version -o err.s
GNU C++ version egcs-2.92.11 19980921 (gcc2 ss-980609 experimental)
(mips-sgi-irix6.4) compiled by GNU C version egcs-2.92.11 19980921 (gcc2
ss-980609 experimental).
../../src/egcs-19980921/gcc/dwarf2out.c:7634: Internal compiler error in
function scope_die_for
More information about the Gcc-bugs
mailing list