This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Autoincrement pass
- To: Michael Hayes <m dot hayes at elec dot canterbury dot ac dot nz>
- Subject: Re: Autoincrement pass
- From: Jeffrey A Law <law at cygnus dot com>
- Date: Mon, 08 Mar 1999 18:34:23 -0700
- cc: egcs at cygnus dot com
- Reply-To: law at cygnus dot com
In message <14051.24583.960926.511554@ongaonga.elec.canterbury.ac.nz>you writ
e:
> However, before I spend some more time cleaning up the pass for
> submission to the egcs project, I would like some feedback about
> possible pitfalls I may have forgotten. Currently, I have made only a
> few changes to flow.c and have put all the autoinc stuff into a
> separate file (autoinc.c). At a later date all the autoinc stuff in
> flow.c could then be culled.
Seems like a reasonable approach. rth even has some comments in the flow.c
todo list to this effect.
We could probably beef this code up by building true def-use webs, but
until we have ssa (which makes building the def-use webs easy) beating on
the existing strategy seems reasonable.
The nice thing about doing this with ssa is you don't have the dead code
problem Joern mentioned. You build the ssa representation of the function.
Then you run dead code elimination (which is trivial on an ssa representation).
Then you use the def-use web to find all the potential optimization sites.
It also occurrs to me one could try to use all the dependency stuff built
by the scheduler to find autoinc opportunities. Just something to ponder.
Jeff