-
-
Notifications
You must be signed in to change notification settings - Fork 808
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add tests for IEEE 754-2019 compliance #365
Comments
Sinpi/cospi without correct rounding in last ulp. |
@munsocket Can you explain in more detail? How are you arriving at this conclusion? Particularly, how did you determine that |
I am just read source code :D
Is not enough because floating point numbers perform rounding after each operation(multiplication) in round-to-nearest-even mode. |
That is not our source, which can be found here. We're not likely to require strict IEEE 754 only requires 1 ulp agreement for a small subset of special functions (e.g., |
Ok, looks legit then :) |
@munsocket Thanks for checking! |
By the way, if your |
Yeah, I saw that you are working on fma emulation. :) Re: TC39. That isn't particularly interesting for us, given that the spec does not require minimum precision requirements. And for good reason: implementations have historically needed the flexibility to trade-off accuracy for increased perf. While In general, we cannot rely on native JavaScript built-ins to always fulfill accuracy guarantees, and this will remain the case. As such, if a user wants certain guarantees, they'll need to rely on userland implementations, such as those provided by |
PR-URL: #6564 Ref: #365 Reviewed-by: Athan Reines <[email protected]>
PR-URL: #6563 Ref: #365 Reviewed-by: Athan Reines <[email protected]>
PR-URL: #6562 Ref: #365 Reviewed-by: Athan Reines <[email protected]>
PR-URL: #6560 Ref: #365 Reviewed-by: Athan Reines <[email protected]>
PR-URL: #6559 Ref: #365 Reviewed-by: Athan Reines <[email protected]>
PR-URL: #6556 Ref: #365 Reviewed-by: Athan Reines <[email protected]>
PR-URL: #6558 Ref: #365 Reviewed-by: Athan Reines <[email protected]>
PR-URL: #6557 Ref: #365 Reviewed-by: Philipp Burckhardt <[email protected]> Signed-off-by: Karan Anand <[email protected]>
PR-URL: #6561 Ref: #365 Co-authored-by: stdlib-bot <[email protected]> Reviewed-by: Philipp Burckhardt <[email protected]> Reviewed-by: Athan Reines <[email protected]> Signed-off-by: Karan Anand <[email protected]>
PR-URL: #6570 Ref: #365 Reviewed-by: Philipp Burckhardt <[email protected]>
PR-URL: #6573 Ref: #365 Reviewed-by: Philipp Burckhardt <[email protected]>
PR-URL: #6599 Ref: #365 Reviewed-by: Philipp Burckhardt <[email protected]>
PR-URL: #6595 Ref: #365 Reviewed-by: Philipp Burckhardt <[email protected]>
PR-URL: #6597 Ref: #365 Reviewed-by: Athan Reines <[email protected]> Signed-off-by: Karan Anand <[email protected]>
PR-URL: #6593 Ref: #365 Reviewed-by: Athan Reines <[email protected]> Signed-off-by: Karan Anand <[email protected]> Co-authored-by: stdlib-bot <[email protected]>
PR-URL: #6594 Ref: #365 Reviewed-by: Athan Reines <[email protected]> Co-authored-by: stdlib-bot <[email protected]>
PR-URL: stdlib-js#6599 Ref: stdlib-js#365 Reviewed-by: Philipp Burckhardt <[email protected]>
PR-URL: stdlib-js#6595 Ref: stdlib-js#365 Reviewed-by: Philipp Burckhardt <[email protected]>
PR-URL: stdlib-js#6597 Ref: stdlib-js#365 Reviewed-by: Athan Reines <[email protected]> Signed-off-by: Karan Anand <[email protected]>
PR-URL: #6620 Ref: #365 Reviewed-by: Athan Reines <[email protected]> Co-authored-by: stdlib-bot <[email protected]>
PR-URL: #6571 Ref: #365 Reviewed-by: Athan Reines <[email protected]> Signed-off-by: stdlib-bot <[email protected]> Co-authored-by: stdlib-bot <[email protected]>
Checklist
Description
To ensure conformance of
@stdlib/math/base/special/*
functions with IEEE 754-2019, we should explicitly include compliance tests in the various test suites of the mathematical functions (e.g.,pow
,exp
, etc) present in the standard. The IEEE 754 standard explicitly states behavior for various edge cases for each mathematical function. By including these tests, we can ensure that the underlying implementations, should they change, always remain IEEE 754 compliant.Related Issues
None.
Questions
No.
Other
No.
The text was updated successfully, but these errors were encountered: