Hello bearophile,

BCS:

If you have no special reason to use float or double and are not IO
or memory space bound, use real. Every machine I know the details of
will use it in the FPU so the only general advantage to not using it
is IO speed and data size.

Take one of the little ray-tracers written in D from my site, test its
running speed compiled with ldc, replace doubles with reals, and time
it again. You will see a nice performance difference. LDC FP
performance is not good if it doesn't use SSE registers.


Ray tracing is very amiable to that sort of optimization, particularly if you are carful about how you write things. Also, I suspect that most cases where SSE is able to make a major difference will spend a lot of time moving large arrays through the CPU so they will have memory size and IO bottleneck concerns, exactly the cases I excepted.

--
... <IXOYE><



Reply via email to