DEC RISC cc chokes on large auto array
Morris Strongson
mms at bnlux1.bnl.gov
Tue May 7 05:31:36 AEST 1991
The following complicated C program gives a
"Segmentation fault (core dumped)" message when compiled and run under the
cc compiler that comes with Ultrix 4.1 on our DECsystem 5000 (RISC). The
value for UIDMAX I really wanted was 65536, but all values starting with
64971 cause it to crash (64970 works). The original was much bigger, but
this boils the problem down to its essential parts. Moving the array above
main works as well.
-------------------------begin included prograsm-----------
#define UIDMAX 64971
main()
{
long x[UIDMAX][2]; /* 0 for total, 1 for file count */
printf("entering disksort\n");
}
-------------------------end included prograsm-----------
This seems to be a rather basic (poor choice of word) program, and I
find it rather distressing that something this simple would fail. Is
there a later version of the compiler available? Thanks.
Morris Strongson INTERNET: mms at bnlux1.bnl.gov
BITNET: mms at bnlux0.BITNET
--
Morris Strongson INTERNET: mms at bnlux0.bnl.gov
BITNET: mms at bnlux0.BITNET
UUCP: ...philabs!sbcs!bnlux0!mms
or bnlux0!mms at uunet.uu.net
More information about the Comp.unix.ultrix
mailing list