comp.lang.ada
 help / color / mirror / Atom feed
From: jim@ghs.com (Jim Gleason)
Subject: Re: AdaMULTI/Ada 95 for Bare Board
Date: 5 Mar 2002 05:27:37 -0800
Date: 2002-03-05T13:27:38+00:00	[thread overview]
Message-ID: <f2c4b613.0203050527.3381229f@posting.google.com> (raw)
In-Reply-To: 3c83596e.9029553@news.demon.co.uk

john.mccabe@emrad.ns.com (John McCabe) wrote in message news:<3c83596e.9029553@news.demon.co.uk>...
> Watch out for allocation of huge stack areas for aggregate assignments
> to arrays...
> 
> e.g.:
> 
> type Large_Array is array (1..100, 1..10, 1..1000) of integer;
> My_Large_Array : Large_Array;
> 
> procedure Initialise
> begin
>     My_Large_Array = (others => 0, others => 0, others => 0);
> end Initialise;
> 
> 
> will attempt to allocate a 4MByte or so block of stack to create an
> aggregate before copying it to the global variable (My_Large_Array).
> Green Hills claim it is *required* by the RM, but certain people who
> were involved in writing the manual disagree!

I don't believe Green Hills claimed this.  Actually, the last two
releases of the Green Hills compiler do NOT use a block of stack
to temporarily hold the initial value before copying into the
global variable.  The global variable (My_Large_Array) is initialized
directly by the generated code.
I hope this clears this up.

Jim Gleason
Green Hills Software, Inc.



  parent reply	other threads:[~2002-03-05 13:27 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <3C7CF687.15D36BBE@avionics.saab.se>
2002-03-04 11:13 ` AdaMULTI/Ada 95 for Bare Board Alfred Hilscher
2002-03-04 11:28   ` John McCabe
2002-03-04 15:12     ` Martin Dowie
2002-03-04 20:16     ` Ted Dennison
2002-03-05  9:32       ` John McCabe
2002-03-05 13:27     ` Jim Gleason [this message]
2002-03-05 14:22       ` John McCabe
2002-03-05 15:42         ` John McCabe
2002-03-06 13:26         ` John McCabe
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox