Hi,
I'm trying to switch KDevelop to incrementally fetch frames
from gdb. One
reason is that -stack-list-frames is not as fast as I'd
like. Another
reason is that if a program is stuck in inifinite recursive,
getting all
10000 frames will take a long time no matter how gdb is
optimized.
So, I first emit
-stack-list-frames 0 30
then
-stack-list-frames 30 60
the
-stack-list-frames 60 90
and so on. However, '-stack-list-frames' fails whenre
there's not enough
frames. Say, if there's just 80 frames the last command
will fail. The only
way to workaround this is to invoke
-stack-info-depth SOME_LIMIT
but then if user wants to see frames above SOME_LIMIT, I'd
need to send
another -stack-info-depth command. So basically, for each
new chunk of
frames that user wants to see I'd need to emit two
commands, first
-stack-info-depth, and then -stack-list-frames, and that's
inconvenient.
Would it be possible to modify the -stack-list-frames
command so that upper
limit only limits the number of frames, but does not cause
an error if
there's less frames?
Thanks,
Volodya
|