std.math performance (SSE vs. real)

via Digitalmars-d digitalmars-d at puremagic.com
Mon Jun 30 23:58:05 PDT 2014


On Monday, 30 June 2014 at 22:58:48 UTC, Walter Bright wrote:
> Wow. Fortunately, there's a switch 
> http://publib.boulder.ibm.com/infocenter/cellcomp/v101v121/index.jsp?topic=/com.ibm.xlcpp101.cell.doc/proguide/spu_sp_diffs.html 
> so it'll work correctly.

That's the same link I provided, but I presume the compiler 
switch kills performance? You have the same with ARM processors. 
NEON (SIMD) instructions are not IEEE754 compliant. VPF is almost 
compliant, but does not support subnormal numbers and flush them 
to zero. Which can be a disaster…

So basically, floating point is not portable unless you give up 
performance or check all expressions with worst case analysis 
based on deficiencies on all current platforms.


More information about the Digitalmars-d mailing list