This is the mail archive of the
mailing list for the GCC project.
Re: Better estimations of costs in outof-ssa
- From: Andrew MacLeod <amacleod at redhat dot com>
- To: Jan Hubicka <jh at suse dot cz>
- Cc: gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 28 Jul 2005 08:47:13 -0400
- Subject: Re: Better estimations of costs in outof-ssa
- References: <20050728072227.GI791@kam.mff.cuni.cz>
On Thu, 2005-07-28 at 03:22, Jan Hubicka wrote:
> outofssa is pretty simple minded about cost estimation of copy instructions it
> inserts. In testcase I was looking at (bresenham line drawing loop) it opted
> to split critical edge within loop instead of adding copy off the loop. This
> patch makes the individual costs to be weighted by profile. This has (very
> small) positive impact to SPEC too (roughly 4 points, but close to noise).
Yeah, this is fine and long overdue.
The cost field is present in add_coalesce for exactly this sort of
reason. When I first implemented it, the loop nesting cost wasn't
trivially available (doesn't that age it...). I punted until it was...
and simply never got back to it. Increasing the cost for critical edges
is also a good idea :-)
Leaving the cost at 1 for size optimization seems like the right thing