This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
allocation of large arrays, GCC 3.2, SPARC
- From: Joe Weening <jweening at ccrwest dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 21 Feb 2003 17:42:13 -0800 (PST)
- Subject: allocation of large arrays, GCC 3.2, SPARC
Using GCC 3.2 on a SPARC/Solaris 8 system (64-bit), if I compile the
following 1-line program:
int s[28][256][16][4096][2][2];
with "gcc -m64 -S", the resulting assembly file contains the line
.common s,3221225472,4
What it should say is
.common s,7516192768,4
so it appears that truncation by 2^32 has occured. This causes a
segmentation fault if code tries to access the higher parts of the
array.
Joe Weening