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

Modify atomic tests to use atomic load #84

Merged
merged 1 commit into from
Apr 13, 2022
Merged

Conversation

ioanev
Copy link
Contributor

@ioanev ioanev commented Apr 11, 2022

Modify the atomic tests in backendTests to use atomic::load rather than pure memory loads as per issue #20.
This as a standalone PR, but also when cherry-picking the commit from #83, passes all tests with both DEBUG=ON/OFF.

This commit modifies the atomic tests in backendTests to use
`atomic::load` rather than pure memory loads as per issue etascale#20.
Copy link
Member

@lundgren87 lundgren87 left a comment

Choose a reason for hiding this comment

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

Aside from the one comment I left (which can most likely be left unchanged) I don't have any objections. There are tests that fail using OpenUCX over Infiniband (atomic tests), but these are not related to the changes here and are documented in a separate issue (#86).

@@ -167,30 +170,27 @@ TEST_F(backendTest, loadOne) {
std::chrono::system_clock::now() + deadlock_threshold;
while(argo::backend::atomic::load(_c) != c_const)
ASSERT_LT(std::chrono::system_clock::now(), max_time);
ASSERT_EQ(c_const, *_c);
Copy link
Member

Choose a reason for hiding this comment

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

This is a slight change of behaviour, but ultimately I think it is sufficient to check that the while loop has finished in order to verify the removed ASSERT_EQ.

@kostis kostis merged commit 7c98be9 into etascale:master Apr 13, 2022
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