This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: More on VIEW_CONVERT_EXPR
- From: "Giovanni Bajo" <giovannibajo at libero dot it>
- To: "Richard Kenner" <kenner at vlsi1 dot ultra dot nyu dot edu>
- Cc: <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 21 Jul 2004 20:14:42 +0200
- Subject: Re: More on VIEW_CONVERT_EXPR
- References: <10407211809.AA14654@vlsi1.ultra.nyu.edu>
Richard Kenner wrote:
> I'm not sure if there's a way around that. I was just trying to
> think of a way to keep this on the front-end's side of the fence.
>
> We did it as an Ada-specific node for the first few years of GNAT's
> history, but it was causing so many problems that we added
> VIEW_CONVERT_EXPR to
> the middle-end a few years ago, specifically, back in November of
> 2001.
Well, this might very well be fixed now with tree-ssa. Do you foresee any
problems switching this back to an Ada-private node?
I think I understand the semantic of VIEW_CONVERT_EXPR, but I don't understand
why it is needed. For instance, in another post, you said:
>You can have a packed record that contains another record at a position that's
not at
> its natural alignment and then do a V_C_E of that field.
Isn't this equivalent in C to a nested structure with some special alignment
attribute on it? And C doesn't use V_C_E. Also C can do unions, which to me
looks like a perfect example of something that *would* need V_C_E but in
practice does not.
--
Giovanni Bajo