This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: GDB MI Interface


On Friday 11 April 2008 02:07:15 Lokesh Kumar wrote:
> Hi all,

Hi Lokesh.

> I want to use the GDB MI interface to communicate with gdb in the
> backend of my software. Surprisingly, the current information on this
> topic is very less on the web. So I thought of turning to the gdb
> community itself. I had the following questions to ask -
> 
> 1. Does the parser for MI output already exists ?

I am not aware of an "official" MI parser. I am using a home grown one
which is ~260 lines of straight-forward C++, It's probably not complete,
but reads the parts I am interested in sufficiently well ;-)

> 2. Are there some frontends debugger that are using this ? As far as I
> know, the ddd and kdb both use the CLI option.

See Vladimir's posting ;-)

Apart from that I am trying to use MI as it relays structured data much better
then the CLI. The two main problems with gdb/MI is that it is (a) incomplete, 
so there are lots of "traditional" commands that do not have an MI equivalent
or whose MI equivalent just chickens out saying "not implemented", and
(b) that it seems to be a constant flux.

It's a bit of a trade-off. _Not_ using MI would give an imaginary frontend
the possibility to use Intel's debugger, too, as this can be configured
to look pretty much like the gdb CLI.

> 3. Has there been any documentation on how to use gdb-MI. The current
> documentation is, as they say, like a reference manual.

Chapter 24 in the docs found on

 http://sourceware.org/gdb/current/onlinedocs/gdb_toc.html

is usable. The problem is that there are different flavours of MI out in
the wild, and point (b) above leading to the necessity to double-check
anything written in the docs with the actual gdb incarnations you want to
support - which is a wee bit less convienient than you could dream of
in a perfect world ;-)

Regards,
Andre'


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]