-
Notifications
You must be signed in to change notification settings - Fork 19
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
Fix sod perpendicular velocities #376
Conversation
@G-071 I think that @shibersag would be the better choice since he reported the bug. |
@shibersag and @dmarce1 could you please have a look at this pr? |
@G-071, I made several tests and this PR does not seem to resolve the issue. And the output I get is: |
@G-071 and @shibersag any update? |
@shibersag and @dmarce1 Can one of you please review the pull request? |
@diehlpk yeah sure. I had to compile the code again on Queen-Bee and now I will continue with testing this PR. |
Flags were not passed correctly for this specific case even with OCTOTIGER_WITH_FAST_FP_CONTRACT=OFF
I've checked the DEVICE_ONLY option and it indeed does the trick. See the comments in #366 for more details. |
@shibersag Part of the PR already some adds some extended testing with a larger sod problem that uses a larger grid and more time-steps than our usual one. It is being tested multiple times (CPU-only, GPU-only and CPU+GPU). We can make it a bit larger still, but I would not go all out as it is run multiple times for each of our automatic tests (10 build configuration times times all kernel configurations) |
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.
LVGTM!
Thanks @G-071 for working on that.
I'm merging this PR. |
This PR addresses the concerns raised #366.
When all kernels are executed on the same device, the perpendicular velocities are zero. If some kernels are executed on the CPU, others on the GPU there were some values not being zero (though still within machine precision).
This can be avoiding by setting a different fp_contract:
The issue can also be avoided by always running everything on the GPU:
Additional tests to check for this issue automatically in the future: