[fpc-devel] Extended type

Florian Klämpfl florian at freepascal.org
Wed Apr 20 09:12:47 CEST 2011


Am 20.04.2011 00:05, schrieb Hans-Peter Diettrich:
> Florian Klaempfl schrieb:
> 
>> Using extended typically hides only bad numerical algorithms. There
>> might be some corner cases where extended is usefull but I general I
>> think it's a matter of bad algorithms.
> 
> Some algorithms convert faster with increased accuracy.

I guess you meant converge? This might be true, but processing of
extended types is also slower: the memory footprint increases and even
worse, extended arrays are typically aligned to 4 or even 16 byte
borders so they take 12 or 16 byte in memory. Further, more complex
floating point operations than +,-,* are also typically slower when the
fpu is set to extended precision. So even if an algorithm converges in
less steps with extended, the overall computation time might not decrease.



More information about the fpc-devel mailing list