-
Notifications
You must be signed in to change notification settings - Fork 162
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
Problem with short circuiting #1927
Comments
Regarding the overwriting, it appears we do not correctly check safety condition 3 for short-circuiting statements of form
In this case the memory block (Incidentally, it's somewhat confusing that the comments use the |
Munksgaard
added a commit
that referenced
this issue
May 1, 2023
Previously, some BasicOps, like Iota didn't have their write sets correctly computed, which caused our short-circuiting pass to incorrectly short-circuit some programs involving iota. Fixes #1927
Munksgaard
added a commit
that referenced
this issue
May 1, 2023
Previously Iota didn't have their write sets correctly computed, which caused our short-circuiting pass to incorrectly short-circuit some programs. Fixes #1927
Munksgaard
added a commit
that referenced
this issue
May 2, 2023
Previously Iota didn't have their write sets correctly computed, which caused our short-circuiting pass to incorrectly short-circuit some programs. Fixes #1927
athas
pushed a commit
that referenced
this issue
May 2, 2023
Previously Iota didn't have their write sets correctly computed, which caused our short-circuiting pass to incorrectly short-circuit some programs. Fixes #1927
razetime
pushed a commit
to razetime/futhark
that referenced
this issue
May 27, 2023
Previously Iota didn't have their write sets correctly computed, which caused our short-circuiting pass to incorrectly short-circuit some programs. Fixes diku-dk#1927
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Consider this program:
Short-circuiting will put the array
src
in the same memory asdst
, but before constructing dst. This means that the construction ofdst
will overwritesrc
.Worse, if
k
is too large, we will write out-of-bounds, as short-circuiting does not ensure that the bounds check is done beforesrc
is constructed.This is a pretty bad bug that can result in anything from invalid results to memory corruption.
The text was updated successfully, but these errors were encountered: