IEEE_754 Compliance
The MIPS4 instruction set contains IEEE-754 non-compliant instructions:
- recip.s/d (reciprocal 1/x) instruction is accurate to 1 ulp
- rsqrt.s/d (reciprocal-sqrt: 1/sqrt(x)) instruction to 2 ulp
-
-OPT:IEEE_arithmetic=X specify degree of non-compliance
and what to do with inf and NaN operands
X = 1 strict IEEE-754 compliance; does not use the recip and rsqrt instructions (-O1,2)
X = 2 optimize 0*x=0 and x/x=1 while x can be NaN (default at -O3)
X = 3 any mathematically valid transformation is allowed, including recip & rsqrt instr.
21 cycles/iteration; 4% peak
1 cycles/iteration; 100% peak