This is the mail archive of the
mailing list for the GDB project.
Re: Extending GDB to provide console over telnet
- From: Kevin Pouget <kevin dot pouget at gmail dot com>
- To: Grigory Tolstolytkin <gtolstolytkin at gmail dot com>
- Cc: gdb at sourceware dot org
- Date: Thu, 29 Sep 2011 14:16:37 +0200
- Subject: Re: Extending GDB to provide console over telnet
- References: <4E845D53.email@example.com>
On Thu, Sep 29, 2011 at 1:58 PM, Grigory Tolstolytkin
> I'm working on extending gdb functionality and would like to start a
> discussion since it might be useful for other people too.
> The idea is to provide users an ability to remotely connect to gdb and
> perform usual debugging interaction while it is already started in Eclipse
> environment via MI interface.
> This allows starting debug locally in Eclipse with connected target
> hardware, for example, and then pass debugging control to a remote user at
> some point.
> Preliminary design is as following:
> 1. gdb is started on a local host either with Eclipse (through MI) or in the
> 2. Remote users will connect to gdb using telnet via TCP.
> ? ?Additional commands need to be introduced to start corresponding TCP
> service. Namely, "start-telnet-service [port]", "stop-telnet-service". TCP
> port can be specified explicitly or hardcoded one (default) will be used.
> 3. Remote users will used standard gdb console command syntax.
> 4. It seems reasonable to allow many users to connect to one instance of gdb
> (Thus having individual internal interpreter for each one).
> 5. Debugging process under Eclipse usually generates a lot of information in
> gdb output. The key idea is to separate MI input/output from the remote user
> ? ?Such debugging process when two or more users are involved into
> controlling gdb might be a bit confusing. For example if users are both
> setting breakpoints their numbers will differ from what users expect and so
> on. But this is not a usual scenario to simultaneously debug the
> application. So users should know what they're doing in such a case. Anyway,
> such operations must not break gdb internals and lead to unpredicted
> Any suggestions, opinions and discussions are highly welcome. I'm also
> already looking into implementation design and will provide details in
> future mails.
the idea sounds interesting, there is just one point I'm not sure to
understand exactly in your email: which interface do you want to
provide to the remote user: command-line (CLI) or MI?
from my point of view, the CLI would be very convenient, it would
allow the use of Eclipse to navigate the source code (instead of
where/list/up/down), and on the other side control the execution and
everything else from the CLI, which is just very powerful when you
know how to use it.
Actually, the best situation would be the other way around, control
GDB 'directly' so that ReadLine history/completion is also available!
(I don't thing it would work over the network, would it?)
Thanks for bringing up the idea,