Make it possible to override the synchonization primitives used by the threadpool using macros.

This commit is contained in:
Rasmus Munk Larsen
2023-05-09 19:36:17 +00:00
parent 1321821e86
commit 96c42771d6
6 changed files with 27 additions and 17 deletions

View File

@@ -51,6 +51,16 @@
#include "src/Core/util/Meta.h"
#include "src/Core/util/MaxSizeVector.h"
#ifndef EIGEN_MUTEX
#define EIGEN_MUTEX std::mutex
#endif
#ifndef EIGEN_MUTEX_LOCK
#define EIGEN_MUTEX_LOCK std::unique_lock<std::mutex>
#endif
#ifndef EIGEN_CONDVAR
#define EIGEN_CONDVAR std::condition_variable
#endif
// IWYU pragma: begin_exports
#include "src/ThreadPool/ThreadLocal.h"
#include "src/ThreadPool/ThreadYield.h"