GCC is 7 times slower than Intel? How to optimize? Need help!!
Andrew Haley
aph@redhat.com
Tue Oct 7 13:06:00 GMT 2008
John Fine wrote:
> Andrew Haley wrote:
>> jackfrost wrote:
>>
>>> Ian Lance Taylor-3 wrote:
>>>
>>>> Try -ffast-math. I think it's the default for icc when optimizing.
>>>>
>>> I've tried -ffast-math with the same result.
>>>
>>
>> You're going to have to look at the generated assembler code.
>>
>>
>
> The generated assembler code wouldn't tell you anything.
>
> Almost all the CPU time is spent inside the exp() function.
We haven't yet determined that.
> I'm confident neither gcc nor Intel10 is inlining the exp() function,
Why are you confident of that? With -ffast-math -O2 that is precisely what
gcc will do. That's why Ian suggested it.
Andrew.
More information about the Gcc-help
mailing list