This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: SSA usage question
- From: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- To: dnovillo at redhat dot com
- Cc: gcc at gcc dot gnu dot org, rth at redhat dot com
- Date: Mon, 7 Jun 04 11:15:09 EDT
- Subject: Re: SSA usage question
I meant "show me code". Both in its original Ada form and what you
propose to generate in GIMPLE.
Sorry.
So, you want a reference like 'a[3]' to show up as 'a[3,v,x]' where 'v'
is TYPE_MIN_VALUE and 'x' is TYPE_SIZE_UNIT? Would 'v' and 'x' be set
sometime before the reference?
Yes, except:
(1) I realized I made a mistake. "x" can't be TYPE_SIZE_UNIT, but has
to be TYPE_SIZE_UNIT divided by the constant which is TYPE_ALIGN of the
element type divided by BITS_PER_UNIT. The reason is that then the
proper multiplication will be made by get_inner_reference for the use
of highest_pow2_factor.
(2) We don't need to do this (and probably shouldn't) if they are constant.
(3) It isn't exactly TYPE_MIN_VALUE but the result of
SUBSTITUTE_PLACEHOLDER_IN_EXPR with that as the first argument and
TREE_OPERAND (array_ref, 0) as the second.
By the way, I'm going to check in my changes to the Ada front end early
this afternoon. It's far from working, but does build, which is an
advantage over what's there. It'll let people see for themselves what's
going on.