Skip to content
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

Avoid overlapping buffer writes in matmul verification #174

Merged
merged 2 commits into from
Apr 14, 2023

Conversation

fknorr
Copy link
Contributor

@fknorr fknorr commented Apr 13, 2023

Déjà vu!

#151 replaces a bool & ref-capture with buffer<bool> with access::all in the matmul verification code. The verification CGF submits a distributed host task though, and when ran on multiple nodes, it produces overlapping writes to the buffer.

To keep distributed verification, this PR replaces the buffer with a host object (matmul even had a comment left explaining that different processes can disagree on their exit code if part of the verification fails!).

Also, since #163 moved matmul from a buffer<bool> to buffer<bool, 0>, I decided to give distr_io the 0-dimensional verification-buffer treatment so we still have an example covering this pattern. That application is sane since verification is done in a master-node host task, which can legally do an all-write access.

@fknorr fknorr requested review from psalz and PeterTh April 13, 2023 16:34
@fknorr fknorr self-assigned this Apr 13, 2023
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clang-tidy made some suggestions

examples/matmul/matmul.cc Show resolved Hide resolved
@fknorr fknorr merged commit 0685d94 into master Apr 14, 2023
@fknorr fknorr deleted the fix-matmul-verify branch April 14, 2023 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants