This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: allocation on the stack
- To: "Mike Stump" <mrs at wrs dot com>,<gcc at gcc dot gnu dot org>
- Subject: Re: allocation on the stack
- From: "Thomas van Gulick" <list at utumno dot student dot utwente dot nl>
- Date: Tue, 28 Sep 1999 04:16:28 +0200
- References: <199909280057.RAA00130@kankakee.wrs.com>
> > From: "Thomas van Gulick" <list@Cal040031.student.utwente.nl>
> > To: <gcc@gcc.gnu.org>
> > Date: Tue, 28 Sep 1999 02:21:22 +0200
>
> > Is there any way to recover from the impossibility of allocating
> > some space on stack which is actually not available? Take for
> > example the following code:
>
> > void function(void) {
> > char buffer[1*1024*1024*1024];
> > cout << "function()\n";
> > }
>
> Sure, just call malloc. Did you expect a different answer?
What actually is the predefined behaviour of a program that runs out of
stack and
can't allocate more stackspace? die?
Thomas
--