On Jan 5, 2013, at 12:02 AM, Rick Mann <rm...@latencyzero.com> wrote: > Postings online suggest this is by design, in that it was more important to > get "close" results faster. Unfortunately, in something like a physic > simulation, the error adds up quickly. I think correct is more important than > fast, and am rather disappointed that IEE754 conformance allows for this > sloppiness.
Unfortunately, guaranteeing exact precision for all transcendental functions at all inputs is worse than just "not fast". Last I heard, even "exact math" implementations guaranteed only 1 ulp precision, because getting every bit right is too slow. This was worse when IEEE 754 was written, because some of today's fast and exact algorithms weren't known yet. IEEE 754 guarantees exact results for + - * / sqrt. Everything else is implementation-defined. Note that if you care about precise reproducibility like the original poster, then "not enough error" is just as bad as "too much error". Sometimes a system can perform a set of operations with extra precision in the intermediate values. (Fused multiply-add instructions often do this.) This will generate a more precise final result, but if what you really wanted was the same result on all hardware then the extra precision is bad. Note also that physics simulations will always need to be careful with the error inherent to finite precision floating-point arithmetic. IEEE specification of exact results for every operation wouldn't solve that. -- Greg Parker gpar...@apple.com Runtime Wrangler _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com