This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Jump optimizations (was Re: g77 performance on ALPHA)
- To: John Wehle <john at feith dot com>
- Subject: Re: Jump optimizations (was Re: g77 performance on ALPHA)
- From: Richard Henderson <rth at cygnus dot com>
- Date: Thu, 2 Sep 1999 13:45:50 -0700
- Cc: law at cygnus dot com, torvalds at transmeta dot com, gcc at gcc dot gnu dot org, toon at moene dot indiv dot nluug dot nl, martin dot kahlert at provi dot de
- References: <199909022023.QAA08884@jwlab.FEITH.COM>
On Thu, Sep 02, 1999 at 04:23:02PM -0400, John Wehle wrote:
> Were you speaking of both cases, or just about:
Both.
> The gcse pass runs before loop. Are you suggesting adding another
> pass, or just making jump smarter by using information and routines
> supplied by gcse and lcm?
A new pass, perhaps run directly after cse2. Or maybe better,
"run again after cse2", as gcse could certainly make use of a
tidier flow graph.
Much of jump.c should be ditched and rewritten -- adding
anything to jump_optimize et al is a losing proposition.
> Any feel for how useful value-range
> propogation is (outside of fixing the unroll problem)?
According to Law, and some friends of his that worked on it, it
doesn't do a whole lot for general C code. There are a few more
cases that show up in Fortran code, e.g.
do i=1,n
do j=1,n
...
enddo
enddo
where we currently have an extra check (1 < N) for the inner loop.
The biggest win is with anything that does array bounds checks.
If you do this, the Java folk will sing your praises.
r~