Skip to content

Commit

Permalink
kp_sampler_skip.cpp: invoke kokkos tools fence
Browse files Browse the repository at this point in the history
  • Loading branch information
vlkale authored May 2, 2024
1 parent 39db70d commit 8d28cf6
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions common/kokkos-sampler/kp_sampler_skip.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,20 +53,17 @@ uint32_t getDeviceID(uint32_t devid_in) {

void invoke_ktools_fence(uint32_t devID) {
if (tpi_funcs.fence != nullptr) {
tpi_funcs.fence(devID);
if (tool_verbosity > 1) {
std::cout << "KokkosP: Sampler attempting to invoke tool-induced fence "
"on device "
<< getDeviceID(devID) << '\n';
}
(tpi_funcs.fence)(devID);
if (tool_verbosity > 1) {
std::cout << "KokkosP: Sampler sucessfully invoked tool-induced fence on "
"device "
<< getDeviceID(devID) << '\n';
std::cout << "KokkosP: Sampler utility sucessfully invoked tool-induced "
"fence on device "
<< getDeviceID(devID) << ".\n";
}
} else {
std::cout << "KokkosP: FATAL: Kokkos Tools Programming Interface's "
"tool-invoked Fence is NULL!\n";
std::abort();
exit(-1);
}
}

Expand Down

0 comments on commit 8d28cf6

Please sign in to comment.