-
Notifications
You must be signed in to change notification settings - Fork 79
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
sinpi: insufficiently precise reference result #860
Comments
Actually, I was wrong here, apologies. I neglected to take into account that That said, I do still think the suggestion to use an existing arbitrary-precision library is a good one, because we do actually already know we have accuracy issues with some functions ( |
The SYCL WG discussed this today. The discussion in ongoing. |
SYCL-CTS shows an error when using DPC++ with our OpenCL implementation.
The value that causes this is the randomly generated input 0.8783900046.
Evaluation with an arbitrary precision tool (calc, https://github.com/lcn2/calc) tells us that the correct result is
That is, the correct result is just under 0x1.7dc5344149045p-2, SYCL-CTS generates a reference result of 0x1.7dc5344149042p-2 (~-2.9 ULP), we generate a result of 0x1.7dc5344149047p-2 (~+2.1 ULP). We are within 4 ULP of the mathematically correct result, which is what the CTS aims to check, so the
sinpi
reference result would need to be calculated with more accuracy to not reject this.I could attempt to create a PR fixing
sinpi
specifically if so desired, but I suspect this is a bigger problem that applies to other functions as well. I am wondering if rather than re-implementing all the functions, an existing arbitrary-precision tool or library could be reused?The text was updated successfully, but these errors were encountered: