This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Unify implementation of 'info os' commands between gdb and gdbserver
- From: Tom Tromey <tromey at redhat dot com>
- To: Kwok Cheung Yeung <kcy at codesourcery dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Tue, 19 Jul 2011 14:12:54 -0600
- Subject: Re: [PATCH] Unify implementation of 'info os' commands between gdb and gdbserver
- References: <4E1C8890.3060304@codesourcery.com>
>>>>> ">" == Kwok Cheung Yeung <kcy@codesourcery.com> writes:
>> Currently, the implementations of the 'info os' command in gdb and
>> gdbserver are maintained separately. This leads to a large amount of
>> code duplication, and discrepencies in the behaviour of the command
>> have already arisen between the two (gdb lists the available info
>> types if 'info os' is issued while gdbserver does not, and gdbserver
>> supports 'info os threads' while gdb does not). This patch attempts to
>> fix that by making the implementation of 'info os' for Linux systems
>> shared between gdb and gdbserver.
>> Auxilliary functions needed to implement 'info os' are moved into the
>> common/ subdirectory. gdb_assert.h, gdb_locale.h and gdb_dirent.h are
>> moved completely, while a subset of the following files are moved to
>> common/:
[...]
I like this patch. I think it is generally a good direction for GDB to
go.
I read it and I did not see anything very objectionable. However, as it
touches the ptid stuff, I would like Pedro to also sign off on it.
>> This necessitates various changes to the makefiles and config files to
>> make sure the right object files are built/linked in. Duplicated
>> functions in gdbserver are removed and the ones in common/ used
>> instead.
One thing I did notice is that you moved gdb_locale.h but gdbserver does
not include any of the configury that might enable the corresponding
functionality.
I am not sure this matters.
Tom