Is there an option to "silent-step"/ "silent-next" (possibly in python and/or mi)?
Philippe Waroquiers
philippe.waroquiers@skynet.be
Sun Feb 12 12:38:33 GMT 2023
As a (not very clean) bypass, you might do something like:
alias silent-next = | next | grep -e some_regexp_to_see what_you_are_interested_in
and if you want to see nothing:
alias silent-next = | next | cat > /dev/null
Philippe
On Fri, 2023-02-10 at 09:59 -0700, Tom Tromey wrote:
> > > > > > "Simon" == Simon Sobisch via Gdb <gdb@sourceware.org> writes:
>
> Simon> For "stepping in the current source" (given a mixed-source) I look for
> Simon> a way to "silent step" / "silent next".
> Simon> This will be useful for example if you debug within Bison and/or Flex
> Simon> generated sources and don't want to step through the state / token
> Simon> machine, having only the Bison / Flex _source_ be visible.
>
> Simon> Getting the source name from the frame and comparing this after a
> Simon> step/next is no big problem in GDB using python
> Simon> gdb.selected_frame().find_sal().symtab.fullname()
>
> Simon> Using GDB in TUI mode I commonly "stay" in the source I'm interested
> Simon> in this way, but the GDB command line gets "flooded" with all the
> Simon> intermediate frame positions I'm not interested in.
>
> Simon> So: is there a way to do a "step"/"next" with suppressing the normal
> Simon> output and mi stop events normally send?
>
> I don't think there is right now. I think suppressing output during
> these kinds of commands is a known issue, but nobody has looked into
> what would be needed to fix it.
>
> Tom
More information about the Gdb
mailing list