-
Notifications
You must be signed in to change notification settings - Fork 86
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
wgsl: Convert all AbstractFloat tests with non-simple errors to using f32 intervals #3493
Conversation
PTAL, I have broken this up into a series of different commits on the PR for easier review, but will be squash them on commit. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
@@ -15,7 +15,8 @@ const mat_vec_cases = ([2, 3, 4] as const) | |||
sparseMatrixF64Range(cols, rows), | |||
sparseVectorF64Range(cols), | |||
'finite', | |||
FP.abstract.multiplicationMatrixVectorInterval | |||
// Matrix-vector multiplication has an inherited accuracy, so abstract is only expected to be as accurate as f32 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for these comments. They very much clarify the issue for a future reader.
Also restricts the number of mix tests being run, since they were taking a very long time to run.
0d0b827
to
eb3477b
Compare
A number of existing tests for AF expressions were incorrectly implemented via performing the accuracy calculations as f64. These need to be converted to using the f32 interval calculations, because absolute, ULP, and inherited AF errors should be as accurate as f32.
This changes additition, cross, determinant, degrees, division, dot, fma, mix, radians, remainder, and various forms of matrix multiplication.
See https://www.w3.org/TR/WGSL/#abstract-float-accuracy for details on why this change is needed.
Requirements for PR author:
.unimplemented()
./** documented */
and new helper files are found inhelper_index.txt
.Requirements for reviewer sign-off:
When landing this PR, be sure to make any necessary issue status updates.