-
Notifications
You must be signed in to change notification settings - Fork 2
Running Google Test with MPI #85
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
Conversation
Yes, this is good news 👍 However, it also shows that we should update this information from Trixi.jl in the Another option would be to set a special environment variable (e.g.,
I'm not sure it's a necessarily synchronization problem: Each rank is supposed to compute the cell averages of their own rank. So when you're checking for the average in cell 929 (928 + 1) in https://github.com/trixi-framework/libtrixi/pull/85/files#diff-bf51675732cd01fd6ac5d3c6f3645b10163b540a95927b3c2b8dc15a529ee673R55, not only does the it give you the value of a different cell, but also of a different variable: In the original case, you had 1600 entries per variable (Structure of Arrays layout), with 2 ranks you only have 800 on each rank. Thus, before you were checking the 929th density value, with 2 ranks you are checking the 129th x-velocity value. Here's a good resource on using Google Test with MPI: https://elib.dlr.de/144193/1/Testing%20HPC%20C%2B%2B%20software%20with%20GoogleTest.pdf It seems like also the t8code folks use it (see, e.g., https://github.com/DLR-AMR/t8code/blob/main/test/t8_gtest_main.cxx), so maybe this could be something to bring up at the next ADAPTEX meeting where t8code folks are in attendance? |
|
Thanks for the detailed analysis and the helpful hints! |
|
Just for reference: |
|
I don't get the errors: For example, https://github.com/trixi-framework/libtrixi/actions/runs/6038153366/job/16383897333?pr=85#step:19:382 compares two values, |
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #85 +/- ##
==========================================
+ Coverage 98.20% 98.23% +0.03%
==========================================
Files 12 12
Lines 500 510 +10
==========================================
+ Hits 491 501 +10
Misses 9 9
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
Exactly! I had used
Units in the Last Place (ULPs), I had not heard of before. I now use |
|
Julia test for the new |
sloede
left a comment
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.
Minor suggestions, but other than that, this looks great!
Some experimental code to run a gtest with MPI.
The good thing is, it seems to work within our CI.
The bad thing is that it fails.
What actually fails is however instructive.