This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: a C routine to optimize GCC for
- To: diep at xs4all dot nl, gcc at gcc dot gnu dot org
- Subject: Re: a C routine to optimize GCC for
- From: Mike Stump <mrs at wrs dot com>
- Date: Thu, 30 Sep 1999 14:41:26 -0700 (PDT)
> Date: Mon, 30 Aug 1999 01:53:52 +0100
> To: gcc@gcc.gnu.org
> From: Vincent Diepeveen <diep@xs4all.nl>
> i've written a short routine where my gcc 2.95 doesn't
> make use of PRO instructions.
> Please don't watch the variable names, they're picked
> randomly for the globals.
> Suffering 10-15 clocks for a branch misprediction is major, it
> a few instructions more to prevent that penalty can get done
> at a rate of 3 instructions a clock!
What happens to performance if board isn't in cache and we fill up the
cache with these unneeed values, and most of the time sweep is true?
I suspect it would die (performance wise).
> Is it so hard to replace the above by PRO instructions?
No, not really. All we have to do is prove that board can be
referenced without faulting (I used your ptr def), that dereferencing
it won't blowout the data cache, that sweep has a good chance of being
false, that the board dereferences have a good chance of being in the
cache (the first might fault, but the rest will be in the same cache
line).