This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC 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: Macros that are defined under config but not used anywhere.


On Thu, 5 Feb 2004, Kazu Hirata wrote:

> Attached is a list of macros that are defined under config but not
> used anywhere.  Feel free to remove these macros if you are a target
> maintainer.  Otherwise, I'll probably submit a patch to remove them.

Cf. the previous list along these lines I sent
<http://gcc.gnu.org/ml/gcc/2002-01/msg00704.html> and subsequent patch
<http://gcc.gnu.org/ml/gcc-patches/2002-01/msg01050.html> for a few of
them (considering the possibility of typos etc. rather than automatically
removing them all), and the summary in bug 3386 comment 12 of a 
methodology for checking for such macros and related cases:

* Macros that are documented but not defined by any targets, or defined
only with one default value (in which case the default should at least go
to defaults.h if there is thought to be value in retaining the macro).

* Macros that are documented but not used in the compiler (whether or not
defined by targets).
   
* Macros that are defined in a target header but not used in the compiler
(including in that config directory), whether or not documented.

* Macros that are tested in the compiler but not defined anywhere and not
documented.

I expect robust scripts to list the various sets of identifiers
defined/used/documented (described in that comment) would be useful for
the contrib directory.

-- 
Joseph S. Myers
jsm@polyomino.org.uk


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