[Insight-developers] CMAKE_BUILD_TYPE=Release and -frename-registers

Luis Ibanez luis.ibanez at kitware.com
Thu Aug 31 10:32:06 EDT 2006


Hi Gaetan,

A while ago (three or four years) we confirmed that -O2 optimization
was not enough for getting the full advantage of the templated code
in ITK.   Since then we have use -O3 level. At the time the test we
done in particular in relation to the ImageIterators, which as you
know are a critical component of all ITK filters.

Do you have a specific reason for not using O3 ?

---


Also, when you say that the test are running "for ever", do you mean
the build process (compilation + linking) or the actual run-time
execution of the test ?

Note that we have machines submitting to the Dahsboard that complete
in 3 hours the full build of ITK with Testing, Examples and the
wrapping for Tcl, Python and Java starting from a scratch.


---

Please let us know,


    Thanks


       Luis


--------------------
Gaetan Lehmann wrote:
> 
> Hi,
> 
> For some time, some tests produced by my release build are running for  
> ever (I have even stop submitting to the dashboard, because the tests 
> are  too long).
> It seems that everything is fine when building with the default options 
> of  my distro:
> 
>   -O2 -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -fomit-frame-pointer -march=i586  
> -mtune=pentiumpro -fasynchronous-unwind-tables
> 
> 
> The only important difference seems to be the -O2 instead of the -O3 
> used  by default for the Release CMAKE_BUILD_TYPE.
> According to gcc man:
> 
>   -O3 Optimize yet more.  -O3 turns on all optimizations specified by -O2
>       and also turns on the -finline-functions and -frename-registers
>       options.
> 
> But -frename-registers is a rejected option in ITK, so shouldn't  
> CMAKE_BUILD_TYPE=Release set the gcc options to
> 
>   -O2 -finline-functions -DNDEBUG
> 
> instead of
> 
>   -O3 -DNDEBUG
> 
> ?
> 
> Thanks,
> 
> Gaetan
> 
> 




More information about the Insight-developers mailing list