This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 1/3] gdbserver/IPA: Export some functions via global function pointers.
- From: "Ulrich Weigand" <uweigand at de dot ibm dot com>
- To: koriakin at 0x04 dot net (Marcin KoÅcielnicki)
- Cc: gdb-patches at sourceware dot org
- Date: Tue, 29 Mar 2016 20:08:34 +0200 (CEST)
- Subject: Re: [PATCH 1/3] gdbserver/IPA: Export some functions via global function pointers.
- Authentication-results: sourceware.org; auth=none
Marcin KoÅ?cielnicki wrote:
> On 14/03/16 18:49, Ulrich Weigand wrote:
> > The more I think about it, the more I tend to agree that your
> > proposal is actually the best solution. I'd still like to give
> > it a couple of days to give others a chance to comment as well ...
>
> Alright, so what should we do about this issue?
Since nobody came up with a better idea, and since your patch doesn't
actually preclude anybody from implementing any better idea they might
come up later (since it doesn't actually change anything in the
gdbserver protocol), I'd say we just go with your patch for now.
However, there does seem to be one issue: your patch changes the
interface between gdbserver and the in-process agent in an incompatible
way. Binaries with an old IPA built in will no longer work with a
new gdbserver, since it will will expect exported symbols like
gdb_collect_ptr, which the old binary doesn't export.
I think it would be preferable to implement a backward-compatible
way where gdbserver checks for the new symbol, and if it isn't
present, falls back to the old symbol.
Bye,
Ulrich
--
Dr. Ulrich Weigand
GNU/Linux compilers and toolchain
Ulrich.Weigand@de.ibm.com