public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] Stack question
@ 2008-02-25 14:41 Tom Deconinck
  2008-02-25 15:18 ` Andrew Lunn
  0 siblings, 1 reply; 3+ messages in thread
From: Tom Deconinck @ 2008-02-25 14:41 UTC (permalink / raw)
  To: ecos-discuss

Hi,

Is there an easy way to know where in memory (exact address) the stack
is located?
In my case (at91sam7se, arm7) the stack size is limited depending on
the address it is located at.
I think the heap should be located at the high end of RAM, but I
haven't got a clue where to look for the stack.

Tom

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ECOS] Stack question
  2008-02-25 14:41 [ECOS] Stack question Tom Deconinck
@ 2008-02-25 15:18 ` Andrew Lunn
  2008-02-25 16:02   ` Tom Deconinck
  0 siblings, 1 reply; 3+ messages in thread
From: Andrew Lunn @ 2008-02-25 15:18 UTC (permalink / raw)
  To: Tom Deconinck; +Cc: ecos-discuss

On Mon, Feb 25, 2008 at 03:41:05PM +0100, Tom Deconinck wrote:
> Hi,
> 
> Is there an easy way to know where in memory (exact address) the stack
> is located?

Which stack? There is the interrupt stack and the idle stack, which
could be the same. If you don't have your own main() function there is
also a system main() which has a stack. Plus all your threads have
stacks.

arm-elf-objdump --syms myprog.elf

or

arm-elf-nm myprog.elf

will show you the symbol table with addresses for all symbols.

     Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ECOS] Stack question
  2008-02-25 15:18 ` Andrew Lunn
@ 2008-02-25 16:02   ` Tom Deconinck
  0 siblings, 0 replies; 3+ messages in thread
From: Tom Deconinck @ 2008-02-25 16:02 UTC (permalink / raw)
  To: ecos-discuss, Andrew Lunn

On Mon, Feb 25, 2008 at 4:17 PM, Andrew Lunn <andrew@lunn.ch> wrote:
> On Mon, Feb 25, 2008 at 03:41:05PM +0100, Tom Deconinck wrote:
>  > Hi,
>  >
>  > Is there an easy way to know where in memory (exact address) the stack
>  > is located?
>
>  Which stack? There is the interrupt stack and the idle stack, which
>  could be the same. If you don't have your own main() function there is
>  also a system main() which has a stack. Plus all your threads have
>  stacks.
>
>  arm-elf-objdump --syms myprog.elf
>
>  or
>
>  arm-elf-nm myprog.elf
>
>  will show you the symbol table with addresses for all symbols.
>
>      Andrew
>

Thanks.
I was looking for stack of my main function. I don't use multiple
threads, so that's one thing less to worry about.

Tom

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2008-02-25 16:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-02-25 14:41 [ECOS] Stack question Tom Deconinck
2008-02-25 15:18 ` Andrew Lunn
2008-02-25 16:02   ` Tom Deconinck

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).