looking for a proof for every optimizier flag (c/c++)
Tim Prince
tprince@computer.org
Mon Jun 3 22:51:00 GMT 2002
On Monday 03 June 2002 06:07, Joerg Beyer wrote:
> Tim Prince wrote:
>
> >
> > This will be platform, (somewhat) language, and compiler version
> > dependent.
>
> agreed. I want to measure the effect of compiler and compile time flags
> on a given hardware. This way one build up an argument to switch from an
> older gcc to gcc-3.1. In an environment with a lot of "never touch a
> running system" people this could be helpful.
>
> Joerg
Taking a very small part of this picture:
compiler: gcc-3.1.1/g77
platform: P-III/700Mhz mobile
benchmark: Livermore Fortran Kernel single precision
(over-all geometric mean result, million "floating point ops"/sec)
common compiler flags: -march=pentium3 -pipe -mfpmath=sse
<-----------varying options ---------->
-O -O2 -fno-reduce-all-givs ...+ -fforce-addr -funroll-loops
Mflops 204 213 221
The optimization "reduce-all-givs" is included in the -O2 package, but seldom
is beneficial for normal g77 code, so I have disabled it. Evidently, the
thinking is different for other languages. ...+ meaning that the final case
includes the preceding set of options. By examining the output summaries of
individual cases it is possible to see which loops are benefiting from each
option. I have the bargain version of SuSE, which has no g77, so I show no
2.95.3 result. I have a corrected (from the buggy public source) C source
version as well; since it becomes a case of showing how a Fortran programmer
can write Fortran in C, it may not be a fair sample of how the same options
would do with most C code.
--
Tim Prince
-------------- next part --------------
A non-text attachment was scrubbed...
Name: o77s_tgz
Type: application/x-gzip
Size: 6261 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc/attachments/20020603/37e13e05/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ll.tgz
Type: application/x-gzip
Size: 71780 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc/attachments/20020603/37e13e05/attachment-0001.bin>
More information about the Gcc
mailing list