This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 1/6] : Commonise various target-descriptions.c functions


On Tue, Jan 16, 2018 at 9:50 AM, Alan Hayward <Alan.Hayward@arm.com> wrote:
> This patch simply moves functionality from target-descriptions.c
> to the common files arch/tdesc.c and arch/tdesc.h.
> No functionality is changed.
> This will allow usage by gdbserver.
> The "#ifndef GDBSERVER" around the functions in arch/tdesc.h will be removed
> in the next patch.
>

It is not right to move everything to arch/ and remove unused bits.  GDB now
is able to visit different tdesc_element, you want to do the same in
GDBserver, and share the code in arch/.  However, tdesc stuff in GDB and
GDBserver are quite different, so the 1st step, IMO, is to make GDBserver
more similar to GDB.  You can change each tdesc-related struct in each
patch, and refactor GDBserver bits.  Then, only move *needed* structures
to arch/, and move one structure in one patch each, if possible.

-- 
Yao (齐尧)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]