Hi, >> So I think the runtime math libraries shoot for .5 ULP (yes, they don't >> always make it, but that's their goal). We should probably have the >> same goal. Going from 0 to 2 ULPs would be considered bad.
Generally the goal is 1ULP in round to nearest - other rounding modes may have higher ULP. The current GLIBC float/double/long double sinh and tanh are 2 ULP in libm-test-ulps (they can be 4 ULP in non-nearest rounding modes). cosh is 1 ULP in round to nearest but up to 3 in other rounding modes. > But we do that everywhere (with -funsafe-math-optimizations or > -fassociative-math). Exactly. And 2 ULP is extremely accurate for fast-math transformations - much better than eg. reassociating additions. Wilco