This is the mail archive of the
mailing list for the GDB project.
Re: [patch] nto target: Code cleanup
Joel Brobecker wrote:
Thanks for quick review!
* i386-nto-tdep.c (i386_nto_target): Remove definition.
(init_i386nto_ops): Use macros to set fields to global
(i386nto_init_abi): Remove unused nto_set_target call.
* nto-tdep.h (nto_set_target): Remove unused declaration.
* nto-tdep.c (nto_set_target): Remove unused function.
Thanks for extracting this part out. This is OK.
I'm wondering how the other targets do this sort of thing,
but my brain seem to be refusing to function at the moment...
Primary motivation for this gymnastics in nto was that we
actually support 5 different cpu platforms and code in
nto-tdep.c is "generic", that is it calls particular nto
target's (that is cpu specific stuff) from there.
My motivation for cleanup is to remove things that don't
seem to do what is expected (like in this example, by
removing this indirection I haven't changed behaviour at all
since the "nto_set_target" simply copies just set functions
from i386_nto_target into current_nto_target.
The whole thing will undergo further cleanups, but right now
I want to bring it as close to what I have as possible.
QNX Software Systems