|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Hi,
how can I recompile PovRay for optimal speed on my machine?
I'm using an athlon (2.6 GHz).
Can I pass some heavy-optimize options to compiler etc?
--
http://www.raf256.com/3d/
Rafal Maj 'Raf256', home page - http://www.raf256.com/me/
Computer Graphics
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Rafal 'Raf256' Maj" <spa### [at] raf256com> wrote in message
news:Xns9509BBE4C7718raf256com@203.29.75.35...
> Hi,
> how can I recompile PovRay for optimal speed on my machine?
>
> I'm using an athlon (2.6 GHz).
>
> Can I pass some heavy-optimize options to compiler etc?
>
> --
> http://www.raf256.com/3d/
> Rafal Maj 'Raf256', home page - http://www.raf256.com/me/
> Computer Graphics
to start, you could try (assuming gcc):
-O3 -DCPU=athlon -march=athlon
for more info, check the man or info pages for gcc. they have an
"optimization" section. check out "-finline-functions" and "-funroll-loops"
maybe more.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Rafal 'Raf256' Maj" <spa### [at] raf256com> wrote in message
news:Xns9509BBE4C7718raf256com@203.29.75.35...
> Hi,
> how can I recompile PovRay for optimal speed on my machine?
>
> I'm using an athlon (2.6 GHz).
>
> Can I pass some heavy-optimize options to compiler etc?
>
ah, see here too:
http://news.povray.org/povray.unix/message/%3C3d4c3ca2%40news.povray.org%3E/#%3C3d4c3ca2%40news.povray.org%3E
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Assuming gcc-3.4.0:
> -O3
Correct,
> -DCPU=athlon
not useful at all for the povray-3.50c Unix source,
> -march=athlon
probably "-march=athlon-xp -mtune=athlon-xp" could be
more suited, and also maybe "-msse" and, as reported elsewhere,
"-mfpmath=sse,387" (but use this one with care).
> check out "-finline-functions"
not useful since automatically turned on by -O3,
> "-funroll-loops"
do _not_ use this one, as it will most likely make the
code slower,
> maybe more.
eventually "-malign-double" "-minline-all-stringops" but there is
no evidence yet that they would actually improve efficiency.
- NC
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
>> maybe more.
I was told recently that using profiling-guided optimization could
also somewhat increase performance on Athlon's. To do so, you have to
compile an intermediate binary using "-fprofile-arcs", then run a
(representative) set of povray scenes, and recompile again this time
with "-fbranch-probabilities" instead of the option above.
Personnaly I had some oddities doing so with gcc-3.4.0 on the
current POV-Ray 3.6 sources, and the speedup was also negligible.
- NC
PS: you'd better not use "-ffast-math" which might be a problem with
e.g. radiosity (untested though).
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Nicolas Calimet wrote:
>>>maybe more.
>
>
> I was told recently that using profiling-guided optimization could
> also somewhat increase performance on Athlon's. To do so, you have to
> compile an intermediate binary using "-fprofile-arcs", then run a
> (representative) set of povray scenes, and recompile again this time
> with "-fbranch-probabilities" instead of the option above.
> Personnaly I had some oddities doing so with gcc-3.4.0 on the
> current POV-Ray 3.6 sources, and the speedup was also negligible.
With gcc 3.4.0 you can use profiling based optimizations with
-fprofile-generate and -fprofile-use.
Christoph
--
POV-Ray tutorials, include files, Sim-POV,
HCR-Edit and more: http://www.tu-bs.de/~y0013390/
Last updated 01 May. 2004 _____./\/^>_*_<^\/\.______
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> I was told recently that using profiling-guided optimization could
> also somewhat increase performance on Athlon's. To do so, you have to
> compile an intermediate binary using "-fprofile-arcs", then run a
> (representative) set of povray scenes, and recompile again this time
> with "-fbranch-probabilities" instead of the option above.
> Personnaly I had some oddities doing so with gcc-3.4.0 on the
> current POV-Ray 3.6 sources, and the speedup was also negligible.
You have the 3.6 sources??
About profiling, the gcc team say that using profiling may speed up the gcc
compiler by about 7% (the profiled compiled compiler is 7% faster :-)
Personally I never got any conclusive evidence that profiled binaries work
faster, but probably it depends on the apllication and on the relevance of
gathered data in the intermediate phase.
Anyway, here are my optimize flags for gcc:
-O3 -fno-exceptions -fno-rtti -fno-check-new -fomit-frame-pointer
(does -O3 implies any of them?)
-funroll-loops (if this slows down depends on the available cache)
-march=pentium4 -mfpmath=sse -msse -msse2 -mmmx
-ffast-math -fno-math-errno -funsafe-math-optimizations -fno-trapping-math
(may be unsafe, certainly not IEEE fp compatibles)
-foptimize-sibling-calls -malign-double -minline-all-stringops
All in all, I am not sure I get better results with any combination of them
than with the plain old -O3 alone.
Using the Intel C Compiler (icc free linux version for non-commercial use)
does not gain anything. using 'icc -O3 -Ob2 -mcpu=pentiumpro -xK
-march=pentiumiii -tpp6 -unroll -ipo -pch -fno-rtti -align' I obtain the
same rendering times as with the gcc binary...
My opinion is that -O3 is the safe bet, more options may gain 3% speed but
to what purpose? 8 or 8.5 seconds is the same for a short rendering, and 72
hours is the same with 73 hours for a long rendering.
But between -O2/-O and -O3 there are important speed differences.
--
-----------------------------------------------------------------------------
Replay-to address is fake. Please replace it
with mferecat (at) numericable (dot) fr.
-----------------------------------------------------------------------------
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> With gcc 3.4.0 you can use profiling based optimizations with
> -fprofile-generate and -fprofile-use.
Ah, that's probably why I had glitches using the other flags.
Thanks, I'll try these out.
- NC
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Ross wrote:
> "Rafal 'Raf256' Maj" <spa### [at] raf256com> wrote in message
> news:Xns9509BBE4C7718raf256com@203.29.75.35...
>
>>Hi,
>>how can I recompile PovRay for optimal speed on my machine?
>>
>>I'm using an athlon (2.6 GHz).
>>
>>Can I pass some heavy-optimize options to compiler etc?
>>
>>--
>>http://www.raf256.com/3d/
>>Rafal Maj 'Raf256', home page - http://www.raf256.com/me/
>>Computer Graphics
>
>
> to start, you could try (assuming gcc):
>
> -O3 -DCPU=athlon -march=athlon
>
> for more info, check the man or info pages for gcc. they have an
> "optimization" section. check out "-finline-functions" and "-funroll-loops"
> maybe more.
>
>
>
Look into the environment variable CFLAGS. I set it to -arch=pentium4
-mcpu=pentium4 -O3. I compile most of my software and it really goes
faster with optimization.
Shalom
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
In article <40cf67e7@news.povray.org> , mf <nos### [at] nossppaammorg> wrote:
> You have the 3.6 sources??
Did you ever take a look at your binary version of 3.6; in particular the
author message output? - it is usually that those who prepare a platforms'
distribution have access to the source code... ;-)
Thorsten
____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde
Visit POV-Ray on the web: http://mac.povray.org
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |