-
Notifications
You must be signed in to change notification settings - Fork 74
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
Example heat-equation #978
Conversation
clang as a CUDA compier complains about:
|
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.
thx for this new example
} | ||
std::cout << "Max error to the exact solution at t = tMax: " << maxError << "\n"; | ||
|
||
return EXIT_SUCCESS; |
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.
Could we return EXIT_FAILURE
if the error is to large. Not sure to large
for this example is but we should set it based on a test run on different hardware.
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.
Agree, we should add a check and report whether the test passed or failed. I will find the appropriate tolerance for this check (this is not immediately obvious). Output of error itself was useful during the development, but not good for testing.
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.
@sbastrakov You can keep the output, I saw it also in many CUDA examples.
Never the less could you please provide the PR with a approximately error range checking.
Please also rebase against #979 |
@jkrude The curent issue is a heap buffer overflow. |
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.
IMO the bug is here
- applied code style guide
I will merge this PR as it is the error margin validation can be pushed as separate PR. |
Alpaka implementation of solving the heat-equation based on a CPU version from @sbastrakov.