-
Notifications
You must be signed in to change notification settings - Fork 436
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
Change the default execution policy behavior of the OpenACC backend #6772
Conversation
…rom synchronous to asynchronous executions. - Change the default OpenACC async_arg value from acc_async_sync to acc_async_noval. - Add acc_wait(async_arg) to scalar reduction operations (parallel_reduce()).
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.
Are kernels still executed in the same order they were submitted (and non-overlapping) with this changes?
@@ -35,15 +35,15 @@ class OpenACCInternal { | |||
|
|||
public: | |||
static int m_acc_device_num; | |||
int m_async_arg = acc_async_sync; | |||
int m_async_arg = acc_async_noval; |
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.
What's the difference between acc_async_noval
and acc_async_sync
?
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.
acc_async_novel
means that the kernels are submitted to a default asynchronous queue, and acc_async_sync
means that kernels are submitted to a default synchronous queue.
In the OpenACC execution model, all tasks submitted to the same OpenACC queue will be executed in order. |
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.
I think this is ok. We could possibly add a comment in the places where acc_async_noval
is used directly that these are places where execution space instances (as a representation of the queue) may need to be passed in.
The OpenACC build passed |
…am-policy) constructs in the OpenACC backend. - This PR handles a missing case not covered by the previous PR kokkos#6772 This PR also fixes the OpenACC backend error in the thread-safety test in PR kokkos#6938.
Change the default execution policy behavior of the OpenACC backend from synchronous to asynchronous executions.