This is the mail archive of the
mailing list for the Cygwin project.
Re: Unfolding the stack
On 12/03/2012 11:20 AM, Michel Bardiaux wrote:
Pretty much. I would just note that this is not cygwin-specific. Nobody
but gdb dares as far as I know.
Alternatively, you could compile with -g and try to traverse the debug
info tables gdb uses to work> around everything nasty gcc does, but
there's no clean API there that I know of.
Since cygwin_stackdump does not dare to tread there...
I meant in the original, non-ported version of the library which you are
porting to cygwin. Presumably it did not call cygwin_stackdump.
Out of curiosity, what is your library currently using to generate backtraces?
Well you just snipped it: pipe/fork/dup to catch the stderr of cygwin_stackdump called in the forked process.
This was in the context of my previous question (see above). Cygwin uses
newlib, not glibc.
There's a backtrace facility in glibc (man backtrace), but it's got a long list of caveats as well, including death by -fomit-frame-pointer (it doesn't use any debug/unwind info emitted by the compiler).
In what package? I have cygwin basics + gcc installed, and no backtrace in any .h.
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple