This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
[ tree-ssa ] May alias speed improvements
- From: law at redhat dot com
- To: gcc at gcc dot gnu dot org
- Date: Thu, 30 Jan 2003 08:31:13 -0700
- Subject: [ tree-ssa ] May alias speed improvements
- Reply-to: law at redhat dot com
As I mentioned on gcc-patches yesterday, we're doing a ton of unnecessary
calls to get_base_symbol, get_alias_set (and its descendants) when
computing may alias information for the tree-ssa code. On the order
of 2.5 billion of calls when around 100k should be sufficient.
I quoted some rough numbers from memory yesterday on the potential
speedups from removing those calls and I thought I'd make those #s a
little more crisp and provide some additional data.
Right now on the tree-ssa branch computing may-alias information for
compile/20001226-1.c takes about 755 seconds with a compiler built
with -O2 -pg. After my (unposted) changes, that time drops to 267
seconds.
One might speculate that the cost of these calls is greatly over
exaggerated by the costs involved with profiling. So I ran
the test on non-profiled tree. Building the may-alias information
in that case takes 258 seconds before my changes and 135 seconds
after my changes.
So while profiling does tend to over exaggerate the cost of these
calls, the unnecessary calls are clearly expensive, even when
not profiling (hell, they still account for nearly 50% of the time
to build the may alias information in a non profiled compilation).
Note -- even with this batch of pending changes, we're still not at
a point where we can enable 20001226-1.c. PHI node insertion for this
test blows up memory usage so bad my machine effectively locks up.
The positive is that with the work Diego and myself have done over the
last few days, getting to the PHI insertion routine takes about 5 minutes
instead of 40 minutes, so it should be feasible to start looking more
closely at the PHI insertion code shortly :-)
Jeff