This is the mail archive of the
mailing list for the GCC project.
Re: Trivial toplev.c patch
- To: shebs at apple dot com
- Subject: Re: Trivial toplev.c patch
- From: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- Date: Fri, 13 Jul 01 06:59:06 EDT
- Cc: gcc-patches at gcc dot gnu dot org, gcc at gcc dot gnu dot org
> So is the idea to replace *all* macros with the target structure?
Yup, just like it says at the top of target.h.
That seems very wrong to me. Has this been discussed widely?
Macros seem like the perfect level of abstraction for this and have worked
well for nearly two decades. Why change them?
I thought the idea of the target structure was to handle some new obscure
hooks, not to replace everything!
It's far cleaner to define macros (which are in one place) instead of having
this huge structure initializer (which can't be done in a named fashion,
unlike macros) and then to generate functions for things that are best
expressed in macros. It means things have to be in *two* places instead of
one. Plus, there are efficiency issues (which I admit are relatively minor).
The model has always been that the .h and .md files are primary, with the
.c file containing "overflow". You seem to be wanting to reverse that.
How will defaulting work if everything has to be in the structure? How do
you override (or undefine) macros in system-specific .h files?
Can you explain the arguments in favor of such a radical change to the way