This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Tracking down gcc-4.0 performance regressions
- From: Georg Bauhaus <bauhaus at uni-duisburg dot de>
- To: Daniel Kegel <dkegel at google dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: Mon, 06 Jun 2005 13:27:58 +0200
- Subject: Re: Tracking down gcc-4.0 performance regressions
- References: <42A3F4CF.8030209@google.com>
Daniel Kegel wrote:
So, I'm looking around for other reports of performance
regressions in gcc-4.0.
I came across this one:
int foo(int a, int b)
{
return a + b;
}
int bar()
{
int x = 0, y = 10;
int c;
for (c=0; c < 123123123 && x > -1; ++c, --y)
x = foo(c, y);
return x;
}
int main()
{
return bar();
}
The for loop is translated rather differently
by GCC 3.4.4 and GCC 4.0.1(pre) on i686 GNU/Linux.
Speed ratio around 85%.
Georg