[RFC] Infinite backtraces...
Thu Dec 2 23:13:00 GMT 2004
> I am not sure I have a sufficiently high-level view of the entire
> code that is involved in unwinding, but it seemed to me that we need
> to add a new architecture-dependent hook that would tell whether a
> given frame is the initial one, and that unwinding can not be done
> past this frame. This naturally pointed to a new gdbarch method.
> Something like gdbarch_upper_most_frame_p (....), with a default
> value that would always return false.
Something I forgot to add was that I thought about adding a frame
method (in the frame_unwind struct). But I don't this this is the
best approach, as you can have several unwinders active at the same
time for the same target, while the end-of-callstack condition
would remain the same reguardless of the type of unwinding we're
I am sort of walking on thin ice here, though. I could very well
imagine a case where we would rely on register value in one case,
and a flag from whatever frame information we find in another case.
This is why I'm mentioning this idea here. JIC.
More information about the Gdb-patches