This is the mail archive of the
mailing list for the GDB project.
Re: [RFC][patch] Allow to disassemble line.
> For whatever it's worth, I miss the extra screen real estate stolen by
> the enlarged prompt (or even the narrower prompt). I use a wider than
> average terminal and most of the times I use disassemble it still runs
> off the right and wraps unreadably. It's fine in examples because
> they have names like "gdb_main" or "bar"...
Same complaint here...
> We've got this layout here with nicely aligned columns but tons of
> whitespace. In a halfway modern world we could do this with color.
> Or bold the address of the current instruction. This would be a real
> interface departure for GDB so I'm curious what others think of it.
> (Yes, I'm thinking of Tufte, why do you ask?)
Wouldn't it be a problem with targets using MI? Or IDEs that run
GDB through a pipe (thinking of Windows in this case)?
I love the idea of starting to take advantage of the terminal capabilities
in order to introduce font properties such as colors or boldness.
> (top) disas
> Dump of assembler code for function gdb_main:
> 0x0000000000454c9e (+0): push %rbp
> 0x0000000000454c9f (+1): mov %rsp,%rbp
Regardless of the above, this suggestion seems fine to me. The repeated
function name has always been clutter (more of the time, I disass the
current function, and I know what it is :-).
> (gdb) x/2i main
> Dump of assembler code for function main:
> 0x44cce0 (+0): sub $0x28,%rsp
> 0x44cce4 (+4): movq $0x0,(%rsp)
This one is a little less obviously nice. I have little user-define
functions such as "ssi" which does "stepi; x /i $pc". Having the
output fit in a couple of lines would really add clutter in this case
> I do observe that disassemble prints leading zeros and examine strips them.
We could start with that...