[VM] Should probably add -fno-gcse to the GCC flags

Andreas Raab andreas.raab at gmx.de
Wed Aug 6 22:41:53 UTC 2003


> Just re-compiling gnu-interp.c with -O2 -fno-gcse results in faster 
> tinyBenchmarks and slower macroBenchmarks:

In this situation I recommend looking at GCCs __attribute__ pragmas. IIRC,
then GCC 3 actually allows "compiler flags" to be set on individual methods
so doing something like

__attribute__((option("no-gcse")))

(not sure about the syntax) in the right places may be a worthwhile little
tweak (this could go into the gnuifier).

> However, I wonder whether we've really got the best optimization 
> flags. I'm using gcc 3.3 now, and it looked like -O3 resulted in 
> worse tinyBenchmarks performance. I should try it with the 
> macroBenchmarks.

Finding "the best" optimizations is a quite complex task here...

Cheers,
  - Andreas



More information about the Squeak-dev mailing list