This is the mail archive of the libc-ports@sources.redhat.com mailing list for the libc-ports project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

MIPS stack frame


Hi,

I am working on retrieving the call stack information on MIPS
platform. Does glibc support backtrace on MIPS either through
backtrace() APIs or any other mechanism ? In i386, glibc has a set of
3 backtrace APIs which use the gcc builtins, __builtin_return_address
and __builtin_frame_address to retrieve the stack frame information.
However there seems to be no such implementation available for MIPs.
Is it true ?  Please correct me if I am wrong.
On MIPS though, I am able to get the current function s return address
using the gcc builtin, __builtin_return_address. I also have the
current function s frame pointer. My doubt is how do I traverse back
to get the information about previous frame and the subsequent ones..?

I tried to feed in the values obtained by gcc builtins to a dynamic
linker function dladdr() and compiled the binary with -rdynamic
option, but couldn succeed for values > 0 for __builtin_return_address
builtin.

Please provide me some pointers regarding this.

Thanks and Regards,
Bharath


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]