This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: First cut on outputing gimple for LTO using DWARF3. Discussion invited!!!!
- From: Tom Tromey <tromey at redhat dot com>
- To: Kenneth Zadeck <zadeck at naturalbridge dot com>
- Cc: GCC Mailing List <gcc at gcc dot gnu dot org>
- Date: 30 Aug 2006 12:56:11 -0600
- Subject: Re: First cut on outputing gimple for LTO using DWARF3. Discussion invited!!!!
- References: <44F2F642.8090408@naturalbridge.com>
- Reply-to: tromey at redhat dot com
>>>>> "KZ" == Kenneth Zadeck <zadeck@naturalbridge.com> writes:
KZ> 2) To have a discussion about the use of DWARF3. I am now against the
KZ> use of DWARF3 for encoding the GIMPLE.
FWIW your arguments convinced me.
I think what matters most is that the resulting format be relatively
well documented (say, better than GIMPLE), efficient, suitable, etc.
Reusing DWARF3 seems cute but inessential.
[...]
KZ> + case TRUTH_NOT_EXPR:
KZ> + case VIEW_CONVERT_EXPR:
KZ> +#if STUPID_TYPE_SYSTEM
KZ> + output_type_ref (ob, TREE_TYPE (expr));
KZ> +#endif
I think VIEW_CONVERT_EXPR needs to be treated like NOP_EXPR and
CONVERT_EXPR in the STUPID_TYPE_SYSTEM case. VIEW_CONVERT_EXPR is a
type-casting expression.
KZ> +/* When we get a strongly typed gimple, which may not be for another
KZ> + 15 years, this flag should be set to 0 so we do not waste so much
KZ> + space printing out largely redundant type codes. */
KZ> +#define STUPID_TYPE_SYSTEM 1
You could write a more compact form by emitting explicit "fake nop"
nodes where needed, and then strip those when reading. I think this
would avoid tweaking the optimizer bugs, as the reloaded trees would
be identical.
This does bring up another point about the format though: there's got
to be some versioning capability in there.
Tom