27 #ifndef INCLUDED_WPTHREAD
28 #define INCLUDED_WPTHREAD
48 #define sched_get_priority_max(policy) +2
49 #define sched_get_priority_min(policy) -2
58 #define PTHREAD_ONCE_INIT 0 // static pthread_once_t x = PTHREAD_ONCE_INIT;
69 LIB_API
int pthread_create(pthread_t* thread,
const void* attr,
void* (*func)(
void*),
void* arg);
71 LIB_API
int pthread_join(pthread_t thread,
void** value_ptr);
84 #define PTHREAD_MUTEX_INITIALIZER pthread_mutex_initializer()
109 LIB_API sem_t*
sem_open(
const char* name,
int oflag, ...);
112 LIB_API
int sem_init(sem_t*,
int pshared,
unsigned value);
135 #endif // #ifndef INCLUDED_WPTHREAD
int pthread_setschedparam(pthread_t thread, int policy, const struct sched_param *param)
int sem_close(sem_t *sem)
int sem_unlink(const char *name)
pthread_mutex_t pthread_mutex_initializer()
int sem_timedwait(sem_t *sem, const struct timespec *abs_timeout)
int pthread_key_create(pthread_key_t *key, void(*dtor)(void *))
void * pthread_mutexattr_t
int pthread_create(pthread_t *thread_id, const void *attr, void *(*func)(void *), void *arg)
int sem_msgwait_np(sem_t *sem)
int sem_destroy(sem_t *sem)
int pthread_mutex_trylock(pthread_mutex_t *m)
int pthread_mutex_lock(pthread_mutex_t *m)
int pthread_mutex_timedlock(pthread_mutex_t *m, const struct timespec *abs_timeout)
int sem_init(sem_t *sem, int pshared, unsigned value)
int pthread_key_delete(pthread_key_t key)
int pthread_mutex_init(pthread_mutex_t *m, const pthread_mutexattr_t *)
int pthread_getschedparam(pthread_t thread, int *policy, struct sched_param *param)
void * pthread_getspecific(pthread_key_t key)
int pthread_mutexattr_settype(pthread_mutexattr_t *attr, int type)
int pthread_setspecific(pthread_key_t key, const void *value)
int pthread_mutex_unlock(pthread_mutex_t *m)
int pthread_once(pthread_once_t *once, void(*init_routine)())
int pthread_equal(pthread_t t1, pthread_t t2)
int pthread_mutexattr_gettype(const pthread_mutexattr_t *attr, int *type)
int pthread_join(pthread_t thread, void **value_ptr)
int pthread_mutex_destroy(pthread_mutex_t *m)
sem_t * sem_open(const char *name, int oflag,...)
unsigned int pthread_key_t
int pthread_cancel(pthread_t thread)
int pthread_mutexattr_destroy(pthread_mutexattr_t *attr)
int pthread_mutexattr_init(pthread_mutexattr_t *attr)