g++ dies on volatile structs
Bill Currie
bcurrie@tssc.co.nz
Wed Jun 10 16:15:00 GMT 1998
NOTE: I'm not subscribed to this list, so please CC me any replies.
Using the code below (ice.cc), I get an internal compiler error.
This is from a freshly ported egcs (hppa1.1-stratus-sysv4), but
gcc-2.8.1 (hppa1.1-stratus-sysv4 and i860-stratus-sysv4 (I got gcc to
work on the bigendian i860)) also exhibits the same error. I haven't
tried it on any other configuration yet (I havn't built a recent g++ at
home) but gcc-2.7.2.1 (hppa1.1-stratus-sysv4) does not produce this
error.
The stage3 and stage2 versions compared successfully (only LANGUAGES=c
done). stage1 was built using gcc-2.7.2.1.
If any other details are needed, just ask.
-----8<--ice.cc-
typedef volatile struct {
long x;
} X;
void foo(int i)
{
X x;
x.x=1;
}
-----8<---------
% ./xgcc -B./ ice.cc -Wall -v
Reading specs from ./specs
gcc version egcs-2.90.29 980515 (egcs-1.0.3 release)
./cpp -lang-c++ -v -isystem ./include -undef -D__GNUC__=2 -D__GNUG__=2
-D__cplusplus -D__GNUC_MINOR__=90 -Dhppa -Dunix -D_FTX -D__hppa__
-D__unix__ -D_FTX -D__hppa -D__unix -Asystem(unix) -Acpu(hppa)
-Amachine(hppa) -D__EXCEPTIONS -Wall -D_PA_RISC1_1 ice.cc
/var/tmp/cca00484.ii
GNU CPP version egcs-2.90.29 980515 (egcs-1.0.3 release) (hppa)
#include "..." search starts here:
#include <...> search starts here:
include
/usr/local/include
/usr/local/hppa1.1-stratus-sysv4/include
/usr/include
End of search list.
./cc1plus /var/tmp/cca00484.ii -quiet -dumpbase ice.cc -Wall -version
-o /var/tmp/cca00484.s
GNU C++ version egcs-2.90.29 980515 (egcs-1.0.3 release)
(hppa1.1-stratus-sysv4) compiled by GNU C version egcs-2.90.29 980515
(egcs-1.0.3 release).
ice.cc: In function `void foo(int)':
ice.cc:9: Internal compiler error.
ice.cc:9: Please submit a full bug report to `egcs-bugs@cygnus.com'.
-----8<---------
TIA
Bill
--
Leave others their otherness
More information about the Gcc-bugs
mailing list