Re: gcc -O1 performs better than gcc -O2

2010-02-15 Thread sam tygier
Joakim Tjernlund wrote: Noticed while optimizing crc16 that gcc -O performed much better than gcc -O2 while doing crc16: I have also seen -O1 beat -O2 when with a large FORTRAN program. http://www.hep.manchester.ac.uk/u/sam/zgoubi-optimise/ Sam

Re: gcc -O1 performs better than gcc -O2

2010-02-14 Thread Joakim Tjernlund
Jakub Jelinek wrote on 2010/02/14 20:21:50: > > On Sun, Feb 14, 2010 at 08:06:20PM +0100, Joakim Tjernlund wrote: > > the warmup isn't really needed after I added memset and inline or not should > > not matter that much are only used once so I think my > > conclusion still stands: gcc 4.3.4 is slo

Re: gcc -O1 performs better than gcc -O2

2010-02-14 Thread Bernd Roesch
Hello On 14.02.10, you wrote: > > Glad to hear that newer versions are back on track, does than mean > that this won't be fixed in gcc 4.3.x series? maybe you test the GCC 4.5.0 Version. I notice in zlib (used in PNG image compression) when there is a image that contain lots same pixel values

Re: gcc -O1 performs better than gcc -O2

2010-02-14 Thread Jakub Jelinek
On Sun, Feb 14, 2010 at 08:06:20PM +0100, Joakim Tjernlund wrote: > the warmup isn't really needed after I added memset and inline or not should > not matter that much are only used once so I think my > conclusion still stands: gcc 4.3.4 is slower with -O2 than -O1 You mean this particular GCC ver

Re: gcc -O1 performs better than gcc -O2

2010-02-14 Thread Richard Guenther
On Sun, Feb 14, 2010 at 8:06 PM, Joakim Tjernlund wrote: > Richard Guenther wrote on 2010/02/14 19:05:24: >> >> On Sun, Feb 14, 2010 at 5:51 PM, Joakim Tjernlund >> wrote: >> > >> > Noticed while optimizing crc16 that gcc -O performed much better >> > than gcc -O2 while doing crc16: >> >> Reduci

Re: gcc -O1 performs better than gcc -O2

2010-02-14 Thread Joakim Tjernlund
Richard Guenther wrote on 2010/02/14 19:05:24: > > On Sun, Feb 14, 2010 at 5:51 PM, Joakim Tjernlund > wrote: > > > > Noticed while optimizing crc16 that gcc -O performed much better > > than gcc -O2 while doing crc16: > > Reducing the noise by adding a loop with trip count 64, making sure > my p

Re: gcc -O1 performs better than gcc -O2

2010-02-14 Thread Richard Guenther
On Sun, Feb 14, 2010 at 5:51 PM, Joakim Tjernlund wrote: > > Noticed while optimizing crc16 that gcc -O performed much better > than gcc -O2 while doing crc16: Reducing the noise by adding a loop with trip count 64, making sure my powersaving model is fixed at performance I see -O1: crc1:f532 cr