Re: Stack backtrace for ARM/Thumb

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 08/04/2010 01:02 PM, Stern, Eli wrote:
> Tried to read a bit about this (unwind). Not much documentation available.
> Seems it was not created for this purpose.

It certainly was!
I know, because I wrote it.  :-)

> Couldn't figure out exactly how to use it.
> 
> Also, it will add quite a large table of data for each function, thus making the total memory consumption larger.
> 
> Wouldn't it make more sense to "convince" the compiler to produce a consistent Thumb stack frame?

I have no idea why you think so.  For exceptions we have
the unwinder data, so we don't need fully-linked stack frames.

I'm not really sure why tpcs frames are so expensive, though.

Andrew.


> Note that the ARM and Thumb stack frames do not have to be identical, since it is possible to differentiate between ARM and Thumb code using the LSBit of the return address.
> So if I get a consistent ARM FP and a consistent Thumb FP, I can traverse the stack.
> 
> Eli Stern
> 
> -----Original Message-----
> From: Andrew Haley [mailto:aph@xxxxxxxxxx] 
> Sent: Monday, July 26, 2010 12:11 PM
> To: Stern, Eli
> Cc: gcc-help@xxxxxxxxxxx
> Subject: Re: Stack backtrace for ARM/Thumb
> 
> ...
> 
> I'd have a look at using _Unwind_Backtrace, which is in libgcc.
> You'll have to compile with full unwinder data and link with
> --no-merge-exidx-entries.  I think the unwinder should be able to cope
> with a mixture of Thumb and ARM frames.
> 
> Andrew.



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux