[PATCH 2/3] Make "disassemble" always use TUI disassembly window
Andrew Burgess
andrew.burgess@embecosm.com
Mon Jan 20 00:48:00 GMT 2020
* Tom Tromey <tom@tromey.com> [2020-01-19 13:07:30 -0700]:
> >>>>> "Tom" == Tom Tromey <tom@tromey.com> writes:
>
> Tom> Currently the "disassemble" command will use the TUI disassembly
> Tom> window if it is already showing. I think it makes more sense to
> Tom> unconditionally switch to it. This patch implements this.
>
> I wonder if this should be limited to the case where the options to
> disassemble are compatible with what the TUI does.
I've wondered for a while if we should have something like:
set tui disassemble-flags ...
where a user can set the flags used by the disassembler. My main
interest initially was /r, but it might be nice if /m and /s could be
supported too, though I'm not quite sure how that might look or work.
Anyway, if we had something like this then using a disassemble command
could effectively be an alternative path to set the flags. So
something like:
(gdb) show tui disassemble-flags
TUI will disassemble using no flags.
(gdb) disassemble /r 0x.....
# TUI ASM window updates, and includes opcodes.
(gdb) show tui disassemble-flags
TUI will disassemble using flags /r.
# User doesn't want the opcodes any more, no problem.
(gdb) set tui disassemble-flags # <-- passing nothing here to
# clear the flags
# TUI updates, but not longer shows opcodes.
Just a thought.
Thanks,
Andrew
More information about the Gdb-patches
mailing list