This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: duplicated code in gdb and gdbserver
> I guess it depends on how many new abstractions one wishes to invent.
> The remote protocol is well-proven, so experimental design is not
> needed. New protocols may have associated state machines that are
> sufficiently close to the remote protocol that one can bridge to them
> easily, or sufficiently far that gdb infrun/core changes would be
> needed. It depends. Until one comes along though, I would propose
> going with what we know.
This extra level of separation seems unecessary to me. Between using an
API and having a child process driven through a serial connection, the API
sounds a lot simpler to me. I don't think we are talking about creating
something new in this case, but just factorizing some code that is in
some large way duplicated between GDB and GDBserver.
--
Joel