Function, file and line information out of '_Unwind_Context' ptr
Gerrit Bruchhäuser
gbruchhaeuser@orga-systems.com
Mon Jun 21 10:26:00 GMT 2004
Hi all,
how can I retreive a backtrace which includes function-name, file and
line information on Tr64-OSF-Alpha (glibc is not supported on this
platform).
Well, I tried:
---
#include <iostream>
#include <stdlib.h>
#include <unwind.h>
static _Unwind_Reason_Code
Trace_cb(struct _Unwind_Context *, void *)
{
std::cout << "Function: " << std::endl;
return _URC_CONTINUE_UNWIND;
}
void
foo()
{
_Unwind_Backtrace(Trace_cb, NULL);
}
int main()
{
foo();
return 0;
}
---
But I don't know how to reteive the information out of 'Unwind_Context'
pointer.
Any idea??
Many thanks,
Gerrit
More information about the Gcc
mailing list