comp.lang.ada
 help / color / mirror / Atom feed
From: rrr.eee.27@gmail.com
Subject: Re: Return unconstrained types in ZFP
Date: Sun, 2 Dec 2012 10:27:57 -0800 (PST)
Date: 2012-12-02T10:27:57-08:00	[thread overview]
Message-ID: <523bdbf9-5a0f-446c-a1ea-92ce58a8fece@googlegroups.com> (raw)
In-Reply-To: <3254b304-ed8b-4601-8a3c-ab3df74d84ad@googlegroups.com>

On Sunday, December 2, 2012 3:38:22 AM UTC+1, Rego, P. wrote:
> Dear fellows, 
> 
> I am trying to implement, for an ATmega2560 (Arduino Mega) micro-controller using ZFP in GNAT-AVR, an USART unconstrained Get string like


Returning unconstrained objects from functions requires the so-called secondary stack in GNAT.  If you want to use it you need the files s-secsta.ad(s|b) and s-stoele.ad(s|b).  (Then you cannot call your run time system a "zero footprint" system anymore as the footprint is > 0)

BTW, AVR-Ada already provides the secondary stack for those who want to use this Ada feature without looking at the generated Asm.  The ATmega2560 is relatively big, you probably dont have to care.  Unconstrained arrays are nice syntax sugar.  If you are short on RAM or flash (I always am) you don't want to use that feature, however.

HTH
    Rolf



  parent reply	other threads:[~2012-12-02 18:27 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-02  2:38 Return unconstrained types in ZFP Rego, P.
2012-12-02  3:29 ` Shark8
2012-12-04  1:08   ` Rego, P.
2012-12-02 18:13 ` Luke A. Guest
2012-12-04  0:59   ` Rego, P.
2012-12-02 18:27 ` rrr.eee.27 [this message]
2012-12-04  0:54   ` Rego, P.
2012-12-03 12:25 ` Stephen Leake
2012-12-04  1:15   ` Rego, P.
2012-12-04  8:40   ` Stephen Leake
2012-12-04 13:21     ` Britt
2012-12-05  3:34       ` Stephen Leake
2012-12-05 13:48         ` Britt
replies disabled

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