parsing gdb MI responses
David Narvaez
david.narvaez at computer.org
Mon Jun 25 16:43:51 UTC 2012
On Mon, Jun 25, 2012 at 10:52 AM, Andreas Pakulat <apaku at gmx.de> wrote:
>
> Hi,
>
> I'm having a bit of a problem with the gdb-support. Apparently its not
> able to parse an MI response, in particular it thinks there's an error, but
> the response itself seems to contain no sign of any errors:
>
> The exception is: MI type error The MI response is:
> ^done,BreakpointTable={nr_rows="2",nr_cols="6",hdr=[{width="7",alignment="-1",col_name="number",colhdr="Num"},{width="14",alignment="-1",col_name="type",colhdr="Type"},{width="4",alignment="-1",col_name="disp",colhdr="Disp"},{width="3",alignment="-1",col_name="enabled",colhdr="Enb"},{width="10",alignment="-1",col_name="addr",colhdr="Address"},{width="40",alignment="2",col_name="what",colhdr="What"}],body=[bkpt={number="1",type="breakpoint",disp="keep",enabled="y",addr="0x0805cc7d",func="main(int,
> char**)",file="/home/andreas/source/main.cpp",fullname="/home/andreas/source/main.cpp",line="90",times="1",original-location="\"/home/andreas/source/main.cpp\":90"},bkpt={number="2",type="breakpoint",disp="keep",enabled="y",addr="",times="1",original-location="\"/home/andreas/source/filename.cpp\":53"},{number="2.1",enabled="y",addr="0x0807c184",func="Squish::TableRange::contentAsXml(Squish::TiXmlNode*,
> int)
> const",file="/home/andreas/source/filename.cpp",fullname="/home/andreas/source/filename.cpp",line="53"},{number="2.2",enabled="y",addr="0xb74018b2",func="Squish::TableRange::contentAsXml(Squish::TiXmlNode*,
> int)
> const",file="/home/andreas/source/filenamecpp",fullname="/home/andreas/source/filename.cpp",line="53"},{number="2.3",enabled="y",addr="0xb719f73e",func="Squish::TableRange::contentAsXml(Squish::TiXmlNode*,
> int)
> const",file="/home/andreas/source/filename.cpp",fullname="/home/andreas/source/filename.cpp",line="53"}]}
>
>
> Is there still someone knowledgeable enough to debug this further? I
> haven't yet tried shutting down KDevelop and restarting it, but I do get
> this on each launch of the application now (the first run-through was ok
> though).
>
>
> Andreas
Hi,
The output shows multiple breakpoint locations for breakpoint 2
(search for number="2 in that output) and the output for multiple
breakpoints in GDB does not conform to their own grammar which breaks
KDevelop's parser. I'm already pinging GDB developers about that
issue[0] but even after it is solved, I think we, on the KDevelop
side, need to brainstorm a bit about how to display multiple locations
for a breakpoint.
David E. Narvaez
[0] http://sourceware.org/bugzilla/show_bug.cgi?id=9659
More information about the KDevelop-devel
mailing list