6#if defined(__cplusplus)
18#if __STDC_NO_THREADS__ == 1
19#error __STDC_NO_THREADS__ defined but <threads.h> included. Something is wrong about your setup.
22#if __STDC_VERSION__ >= 201112L
23#define thread_local _Thread_local
26#define ONCE_FLAG_INIT 0
28#define TSS_DTOR_ITERATIONS 4
47#define _MTX_UNLOCKED 0
49#define _MTX_CONTESTED 2
130#if defined(__cplusplus)
__UINT64_TYPE__ tid_t
Thread Identifier.
Task State Segment structure.
_PUBLIC int cnd_init(cnd_t *cond)
_PUBLIC void call_once(once_flag *flag, void(*func)(void))
_PUBLIC int mtx_timedlock(mtx_t *_RESTRICT mtx, const struct timespec *_RESTRICT ts)
int(* thrd_start_t)(void *)
_PUBLIC int mtx_lock(mtx_t *mtx)
_PUBLIC thrd_t thrd_current(void)
_PUBLIC int mtx_init(mtx_t *mtx, int type)
_PUBLIC int thrd_sleep(const struct timespec *duration, struct timespec *remaining)
_PUBLIC int thrd_equal(thrd_t thr0, thrd_t thr1)
_PUBLIC int cnd_timedwait(cnd_t *_RESTRICT cond, mtx_t *_RESTRICT mtx, const struct timespec *_RESTRICT ts)
_PUBLIC int tss_create(tss_t *key, tss_dtor_t dtor)
_PUBLIC void thrd_yield(void)
_PUBLIC int mtx_unlock(mtx_t *mtx)
_PUBLIC void cnd_destroy(cnd_t *cond)
_PUBLIC void tss_delete(tss_t key)
_PUBLIC int cnd_broadcast(cnd_t *cond)
_PUBLIC int cnd_signal(cnd_t *cond)
_PUBLIC int thrd_create(thrd_t *thr, thrd_start_t func, void *arg)
_PUBLIC int thrd_detach(thrd_t thr)
_PUBLIC int thrd_join(thrd_t thr, int *res)
_PUBLIC void * tss_get(tss_t key)
int cnd_wait(cnd_t *cond, mtx_t *mtx)
_PUBLIC _NORETURN void thrd_exit(int res)
_PUBLIC void mtx_destroy(mtx_t *mtx)
_PUBLIC int tss_set(tss_t key, void *val)
_PUBLIC int mtx_trylock(mtx_t *mtx)
void(* tss_dtor_t)(void *)