This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: "Hello World" core dumps
- To: dosreis at cmla dot ens-cachan dot fr (Gabriel Dos Reis)
- Subject: Re: "Hello World" core dumps
- From: Mike Harrold <mharrold at cas dot org>
- Date: Mon, 15 Nov 1999 13:37:29 -0500 (EST)
- Cc: gcc-bugs at gcc dot gnu dot org, labour at cmla dot ens-cachan dot fr
>
>
> The following causes a core dump on a Solaris-2.[567] and on a
> i386-linux
>
> #include <stdio.h>
>
> int main()
> {
> unsigned char buf[10000000];
> printf("Hello World\n");
> }
>
> This is a snippet from a real-life application.
>
> Any thoughts?
>
> -- Gaby
>
Check the system limits (ulimit -a from (ba)sh-type shells).
I'd suspect you're exceeding the stack limit.
/Mike