From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,69431b06fe9a3239 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Path: g2news2.google.com!postnews.google.com!k7g2000yqj.googlegroups.com!not-for-mail From: Lucretia Newsgroups: comp.lang.ada Subject: Re: How do I disable elaboration code on this Date: Mon, 11 Apr 2011 16:08:22 -0700 (PDT) Organization: http://groups.google.com Message-ID: References: <58bc4fb4-5f6a-48d6-9c98-0dde7ac619df@p16g2000vbo.googlegroups.com> <4da2176e$0$6977$9b4e6d93@newsspool4.arcor-online.net> <93b20b91-03ed-48d2-87b6-a109127a5a4f@l18g2000yql.googlegroups.com> <6bca8b26-152f-482c-95c0-1abf88b6b29b@a26g2000vbo.googlegroups.com> NNTP-Posting-Host: 90.194.162.198 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1302563302 881 127.0.0.1 (11 Apr 2011 23:08:22 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Mon, 11 Apr 2011 23:08:22 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: k7g2000yqj.googlegroups.com; posting-host=90.194.162.198; posting-account=L2-UcQkAAAAfd_BqbeNHs3XeM0jTXloS User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux x86_64; en-GB; rv:1.9.1.16) Gecko/20110302 Iceweasel/3.5.16 (like Firefox/3.5.16),gzip(gfe) Xref: g2news2.google.com comp.lang.ada:19733 Date: 2011-04-11T16:08:22-07:00 List-Id: On Apr 11, 12:59=A0pm, Simon Clubley wrote: > On Cortex M3 devices using C, this array is placed in it's own section > and is placed at address 0 by the linker script. Yup, easy in C. just a static const array of pointers to functions in a separate file, the linker is then used to slap it into place. > The issue here is that when the Cortex M3 comes out of reset it reads, > and loads, the stack pointer from the first longword in that array > and then jumps to the address specified by the second longword. > > To Luke: are you targetting only the Cortex M3 or traditional ARM7 > devices as well ? Not yet. It's just that the M3 doesn't actually need ASM for C/C++ projects, I wanted to see if I could do the same from Ada. At the moment, I have a Cortex-M3 board so that shall be my target, I intend to write an equivalent of CMSIS for use as the BSP for these chips. As for ARM7 or other ARM's, there's no real reason why you couldn't provide something similar. No need for a wrapper, as depending on the platform, you'd provide a different BSP and a different startup and for bigger ARM's, that'd be ASM. This ASM could be conditionally assembled if need be for different ARM's. Thanks, Luke.