delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/10/12/07:51:26

Date: Sun, 12 Oct 1997 13:47:49 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: "Salvador Eduardo Tropea (SET)" <salvador AT inti DOT edu DOT ar>
cc: djgpp AT delorie DOT com
Subject: Re: Compiler crashes...
In-Reply-To: <m0xJGrj-000S1oC@inti.gov.ar>
Message-ID: <Pine.SUN.3.91.971012134726.8447B-100000@is>
MIME-Version: 1.0

On Thu, 9 Oct 1997, Salvador Eduardo Tropea (SET) wrote:

> Seems that gcc isn't just calling malloc (or calloc) to create the
> array.

I wasn't talking about memory required to create the array.  The array
isn't created by cc1, it is the linker which does it.  cc1 only needs
to parse the source, it does not allocate the space for the variables
it parses.

> Seems that a lot of tasks are involved in this simple thing
> so I can beleive that a 256Kb couldn't be enough but not Mbs of
> virtual memory.

My testing indicates (see my other mail in this thread) that cc1
indeed uses malloc'ed storage, not the stack space, and that it's
probably the parse tree build process that's responsible for the
outrageous memory usage.

> I was getting simple crashes I was tried enlarging the stack.

It might be because of the DPMI server you are using.  I tested under
CWSDPMI and Windows 95, and only saw "out of virtual memory" messages
under CWSDPMI (Windows 95 just paged, but let the compiler finish).

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019