www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/12/06/02:52:50

X-Authentication-Warning: delorie.com: mailnull set sender to djgpp-bounces using -f
Date: Thu, 6 Dec 2001 09:48:08 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Tom Kent <tomkent AT iastate DOT edu>
cc: djgpp AT delorie DOT com
Subject: Re: Max array size
In-Reply-To: <9ump4d$186$1@news.iastate.edu>
Message-ID: <Pine.SUN.3.91.1011206094749.15950J-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Wed, 5 Dec 2001, Tom Kent wrote:

> I was wondering if there was any maximum array size is.  I've been trying to
> compile a program that has an array of floats with dimensions 10,000x16.  It
> compiles fine, but then when i go to run it I get an error.

Sounds like you are using an automatic array which is too large for
the run-time stack.  See section 15.9 of the DJGPP FAQ list for a
related discussion.

> Because of this I was hypothesizing a potential limitation either with this
> compiler or with DOS.

It's not a DOS limitation, it's a limitation of the DJGPP run-time
environment: the stack is allocated in its entirety at startup, and
cannot be expanded afterwards.  So the default stack size is not very
large, only 512KB, so as not to punish ``normal'' programs with too
large memory requirements.

- Raw text -


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