This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug backtrace/9838] New: Add "friendly stack view" feature
- From: "daniel dot santos at pobox dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: 12 Feb 2009 00:55:51 -0000
- Subject: [Bug backtrace/9838] New: Add "friendly stack view" feature
- Reply-to: sourceware-bugzilla at sourceware dot org
For C and C++, a friendly stack view feature could really be handy, especially
when troubleshooting odd issues where the need to examine the stack and
disassembly more closely is required. I haven't tried the /m feature yet for
the new enhanced disassembly (src + disassembly), but here's my basic idea.
The command would be something like "info friendly-frame" or "info ff", whatever
(or maybe a modified "info frame" output). The output would be the contents of
the stack in a format something like the following:
sp+0x<offset> <raw bytes in hex> <alignment padding>[<C/C++ type>] <C/C++
variable name>=<value>[<additional value information>]
So if I happen to have some C code that looks like this and I break on line 4:
1 int main(int argc, char *argv[]) {
2 int jack = 1;
3 int *pjack = &jack;
4 printf("stuff\n");
5 }
if I'm debuging at line 4 and I invoke this command ("info ff" or something),
this would be a possible output format (and I don't know the real order these
would appear in the assembly, so ignore any errors there)
sp+
(gdb) info friendly-stack (or just "stack" after specifying something to say it
should be friendly)
sp+0x00: ef be ad de 00 00 00 00 int* pjack=0xdeadbeef
sp+0x08: 01 00 00 00 int jack =1
So here, "0x00000000deadbeef" a fictional pointer. This could be helpful in a
lot of debugging situations.
--
Summary: Add "friendly stack view" feature
Product: gdb
Version: 6.8
Status: UNCONFIRMED
Severity: enhancement
Priority: P2
Component: backtrace
AssignedTo: unassigned at sourceware dot org
ReportedBy: daniel dot santos at pobox dot com
CC: gdb-prs at sourceware dot org
GCC build triplet: all
GCC host triplet: all
GCC target triplet: all
http://sourceware.org/bugzilla/show_bug.cgi?id=9838
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.