8#include <dispenso/thread_id.h>
12std::atomic<uint64_t> nextThread{0};
13constexpr uint64_t kInvalidThread = std::numeric_limits<uint64_t>::max();
14DISPENSO_THREAD_LOCAL uint64_t currentThread = kInvalidThread;
17 if (currentThread == kInvalidThread) {
18 currentThread = nextThread.fetch_add(uint64_t{1}, std::memory_order_relaxed);