This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: gdb/mi or python interface for front end
- From: Tom Tromey <tromey at redhat dot com>
- To: Bob Rossi <bob at brasko dot net>
- Cc: gdb at sourceware dot org
- Date: Fri, 23 Aug 2013 08:03:27 -0600
- Subject: Re: gdb/mi or python interface for front end
- References: <20130823005118 dot GA8847 at bob-VirtualBox>
Bob> I would like some advice. It currently uses annotate level 2
Bob> for communication. Should I look into gdb/mi or should i look
Bob> into scripting gdb with the python interface?
Definitely stop using annotations.
MI is what all the other UIs for gdb use. It is reasonably complete
and, while odd and/or buggy in some places, it is at least well known,
so you'll have plenty of company for either discussing bugs or
commiseration ;-)
I think using Python is cool, but I must admit it has a couple of
potential drawbacks. First, it limits the versions of gdb your tool can
use -- older gdbs do not have Python, and it is an optional feature
(though most distros build it in). Also, it is not as complete as MI in
some ways, so you may encounter holes that you need to be filled before
you can implement some feature. On the plus side, I think interacting
with Python is generally simpler than interacting with MI.
Tom