This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [tree-ssa]: Easy way to get default def of a variable?
- From: Daniel Berlin <dberlin at dberlin dot org>
- To: Diego Novillo <dnovillo at redhat dot com>
- Cc: "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Date: Wed, 4 Jun 2003 18:49:30 -0400
- Subject: Re: [tree-ssa]: Easy way to get default def of a variable?
On Wednesday, June 4, 2003, at 06:21 PM, Diego Novillo wrote:
On Wed, 2003-06-04 at 16:48, Daniel Berlin wrote:
This works, but it's slow, and it *seems* there should be a table or
something of the "first versions" of variables.
That wouldn't be hard to register. It could be stored in a hash table
indexed by VAR_DECL. If it's only useful for a single pass, we should
probably trigger it with a flag. If you think it could be useful in
other parts, we could then enable it by default.
No idea yet.
I believe this is what Open64 refers to as the "zero version", and it
has such a table, but i may be wrong.
They use zero versions to avoid the explosion of SSA names generated in
the presence of heavy aliasing. They run a pass that goes through the
variables and when there are many versions of a variable that are only
used in MUs/CHIs (ie, no real references), they just create a zero
version for the variable that essentially means that the variable is
used and defined in unknown ways.
Ahh, gotcha.
I never quite figured out what it was, so i guessed.
Wrong, apparently.
It's a mechanism for handling the
explosion of version numbers. Apparently to speed up optimizers so
that
they don't have to chase long UD chains for things that aren't worth
it.
That's what I vaguely remember, anyway. It's been a few months.
Diego.