-
Notifications
You must be signed in to change notification settings - Fork 14
Add tests #33
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
Open
tonghaining
wants to merge
7
commits into
KhronosGroup:main
Choose a base branch
from
tonghaining:manual
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Add tests #33
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
fd55868
Add tests
tonghaining 2853957
Add asmo-weak.test
tonghaining f72e5e6
Add two tests adapted from Figure 5 of paper: Heterogeneous-race-free…
tonghaining d051a07
Merge pull request #1 from tonghaining/sb-dr
tonghaining 6bc11c7
Remove scope of private operations
tonghaining 889fcd9
Add Control Barrier Tests
tonghaining 95db5bd
Merge pull request #2 from tonghaining/cb
tonghaining File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| // Producer-Consumer pattern using named barriers. | ||
| // Atomic operations are non-private and thus the load and store are in locord. | ||
| // Barriers are acq_rel and thus they are in sw. | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| ld.atom.scopewg.sc0 x = 1 | ||
| cbar.acq.rel.scopewg.semsc0 0 | ||
| NEWTHREAD | ||
| cbar.acq.rel.scopewg.semsc0 0 | ||
| st.atom.scopewg.sc0 x = 1 | ||
| NOSOLUTION consistent[X] && #dr=0 | ||
| NOSOLUTION #dr>0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| // Producer-Consumer pattern using named barriers. | ||
| // Load and store are non-private and thus in locord. | ||
| // Barriers are acq_rel and thus they are in sw. | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| ld.nonpriv.sc0 x = 1 | ||
| cbar.acq.rel.scopewg.semsc0 0 | ||
| NEWTHREAD | ||
| cbar.acq.rel.scopewg.semsc0 0 | ||
| st.nonpriv.sc0 x = 1 | ||
| NOSOLUTION consistent[X] && #dr=0 | ||
| NOSOLUTION #dr>0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| // Producer-Consumer pattern using named barriers. | ||
| // Load and store are private and thus not in locord. | ||
| // Barriers are acq_rel and thus they are in sw. | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| ld.sc0 x = 1 | ||
| cbar.acq.rel.scopewg.semsc0 0 | ||
| NEWTHREAD | ||
| cbar.acq.rel.scopewg.semsc0 0 | ||
| st.sc0 x = 1 | ||
| SATISFIABLE consistent[X] | ||
| SATISFIABLE #dr>0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| // Producer-Consumer pattern using named barriers. | ||
| // Atomic operations are non-private and thus the load and store are in locord. | ||
| // Barriers are not acq_rel and thus they are not in sw. | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| ld.atom.scopewg.sc0 x = 1 | ||
| cbar.scopewg 0 | ||
| NEWTHREAD | ||
| cbar.scopewg 0 | ||
| st.atom.scopewg.sc0 x = 1 | ||
| SATISFIABLE consistent[X] && #dr=0 | ||
| NOSOLUTION #dr>0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| // Producer-Consumer pattern using named barriers. | ||
| // Load and store are non-private and thus in locord. | ||
| // Barriers are not acq_rel and thus they are not in sw. | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| ld.nonpriv.sc0 x = 1 | ||
| cbar.scopewg 0 | ||
| NEWTHREAD | ||
| cbar.scopewg 0 | ||
| st.nonpriv.sc0 x = 1 | ||
| SATISFIABLE consistent[X] | ||
| SATISFIABLE #dr>0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| // Test if thread 3 and thread 4 can read updates to x in conflicting order | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| st.sc0 x = 1 | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| st.sc0 x = 2 | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| ld.atom.scopedev.sc0 x = 1 | ||
| ld.atom.scopedev.sc0 x = 2 | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| ld.atom.scopedev.sc0 x = 2 | ||
| ld.atom.scopedev.sc0 x = 1 | ||
| SATISFIABLE consistent[X] && #dr>0 | ||
| SATISFIABLE consistent[X] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| // Non-atomic memory operations may be observed by one thread in a different order than they were written by another thread | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| st.sc0 x = 1 | ||
| st.sc0 x = 2 | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| ld.sc0 x = 2 | ||
| ld.sc0 x = 1 | ||
| SATISFIABLE consistent[X] | ||
| NOSOLUTION consistent[X] && #dr=0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| // Av/Vis + Rel/Acq forbids the behavior | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| st.av.scopedev.sc0 x = 1 | ||
| st.atom.rel.scopewg.sc0.semsc0 y = 1 | ||
| NEWSG | ||
| NEWTHREAD | ||
| ld.atom.acq.scopewg.sc0.semsc0 y = 1 | ||
| ld.vis.scopedev.sc0 x = 0 | ||
| NOSOLUTION consistent[X] | ||
| NOSOLUTION consistent[X] && #dr=0 | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| // Rel/Acq alone is not enough to forbid the behavior | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| st.sc0 x = 1 | ||
| st.atom.rel.scopewg.sc0.semsc0 y = 1 | ||
| NEWSG | ||
| NEWTHREAD | ||
| ld.atom.acq.scopewg.sc0.semsc0 y = 1 | ||
| ld.sc0 x = 0 | ||
| SATISFIABLE consistent[X] | ||
| NOSOLUTION consistent[X] && #dr=0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| // Adapted from Figure 5 of paper: Heterogeneous-race-free Memory Models | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| st.atom.rel.scopewg.sc0.semsc0 x = 1 | ||
| ld.atom.acq.scopedev.sc0.semsc0 y = 0 | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| st.atom.rel.scopewg.sc0.semsc0 y = 1 | ||
| ld.atom.acq.scopedev.sc0.semsc0 x = 0 | ||
| SATISFIABLE consistent[X] && #dr>0 | ||
| NOSOLUTION consistent[X] && #dr=0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| // Adapted from Figure 5 of paper: Heterogeneous-race-free Memory Models | ||
| NEWWG | ||
| NEWSG | ||
| NEWTHREAD | ||
| st.atom.rel.scopewg.sc0.semsc0 x = 1 | ||
| ld.atom.acq.scopedev.sc0.semsc0 y = 0 | ||
| NEWSG | ||
| NEWTHREAD | ||
| st.atom.rel.scopewg.sc0.semsc0 y = 1 | ||
| ld.atom.acq.scopedev.sc0.semsc0 x = 0 | ||
| SATISFIABLE consistent[X] && #dr=0 |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.