This is the mail archive of the
mailing list for the GCC project.
Re: Semantics of -fdump-ast?
- To: Diego Novillo <dnovillo at redhat dot com>
- Subject: Re: Semantics of -fdump-ast?
- From: Nathan Sidwell <nathan at codesourcery dot com>
- Date: Fri, 31 Aug 2001 10:36:01 +0100
- CC: gcc at gcc dot gnu dot org
- Organization: Codesourcery LLC
- References: <20010812231850.A9404@tornado.cygnus.com>
Diego Novillo wrote:
Sorry for the tardy reply
> I'm probably misinterpreting what invoke.texi says about
> -fdump-ast-<name>-<num>, but it looks as if the semantics for
> <num> are global to all the possible dump names.
Yes, primarily because it was the simplest thing to do.
> I would like to add various -fdump-ast names for the tree SSA
> passes, but I need 'num' to have different meanings according to
> the name used. In particular, bit0 and bit1 as they're currently
> defined would be useless for the SSA or CFG dumps.
> Is that feasible? Thanks.
It's possible, but IMHO confusing. How about allocating new bits for
the functionality you want? How many flags are you anticipating? If
there are many, I'd suggest implementing name->value mapping machinery
in the option parsing, so you can say,
-fdump-ast-optimized=christmas-tree // joke
and have the right thing happen.
Dr Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery LLC
'But that's a lie.' - 'Yes it is. What's your point?'
email@example.com : http://www.cs.bris.ac.uk/~nathan/ : firstname.lastname@example.org