Skip to content

Commit

Permalink
Remove Sentinel struct from Threads
Browse files Browse the repository at this point in the history
  • Loading branch information
Rombur committed Oct 26, 2023
1 parent b875be7 commit 6ac5aa8
Showing 1 changed file with 0 additions and 14 deletions.
14 changes: 0 additions & 14 deletions core/src/Threads/Kokkos_Threads_Instance.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -73,18 +73,6 @@ int s_thread_pool_size[3] = {0, 0, 0};
void (*volatile s_current_function)(ThreadsInternal &, const void *);
const void *volatile s_current_function_arg = nullptr;

struct Sentinel {
~Sentinel() {
if (s_thread_pool_size[0] || s_thread_pool_size[1] ||
s_thread_pool_size[2] || s_current_function || s_current_function_arg ||
s_threads_exec[0]) {
std::cerr << "ERROR : Process exiting while Kokkos::Threads is still "
"initialized"
<< std::endl;
}
}
};

inline unsigned fan_size(const unsigned rank, const unsigned size) {
const unsigned rank_rev = size - (rank + 1);
unsigned count = 0;
Expand Down Expand Up @@ -549,8 +537,6 @@ void ThreadsInternal::initialize(int thread_count_arg) {
unsigned use_numa_count = 0;
unsigned use_cores_per_numa = 0;
bool allow_asynchronous_threadpool = false;
// need to provide an initializer for Intel compilers
static const Sentinel sentinel = {};

const bool is_initialized = 0 != s_thread_pool_size[0];

Expand Down

0 comments on commit 6ac5aa8

Please sign in to comment.