This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Converting tm.h macros to functions
- To: Fergus Henderson <fjh at cs dot mu dot oz dot au>, "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Subject: Re: Converting tm.h macros to functions
- From: Mark Mitchell <mark at codesourcery dot com>
- Date: Wed, 20 Jun 2001 15:56:27 -0700
> How about defining wrapper functions or macros?
> E.g.
>
> #define asm_output_int(i,f) (*target.asm_stuff.asm_output_int)((i),(f))
>
I'm not into that because that makes `target' a permanently global thing.
Eventually,
I'd love to see us eliminate all global variables and just pass around an
`a_compiler'
object. Then we could have a compiler-server -- compile all your files in
separate
threads. OK, I guess the heat has fried my brain a little...
Seriously, I'd like to not do the macro thing -- we have too many macros.
A little
typing won't hurt us.
On the other hand, this is a very minor issue compared to the benefits that
will
accrue from packaging up the macros in these vtables. If people want to do
as you
suggest, I won't try to stop them. :-)
--
Mark Mitchelll mark@codesourcery.com
CodeSourcery, LLC http://www.codesourcery.com