|
nsz |
d7c151 |
#include <pthread.h>
|
|
nsz |
d7c151 |
#define T(t) (t*)0;
|
|
nsz |
d7c151 |
#define C(n) switch(n){case n:;}
|
|
nsz |
d7c151 |
static void f()
|
|
nsz |
d7c151 |
{
|
|
nsz |
d7c151 |
T(pthread_attr_t)
|
|
nsz |
d7c151 |
T(pthread_barrier_t)
|
|
nsz |
d7c151 |
T(pthread_barrierattr_t)
|
|
nsz |
d7c151 |
T(pthread_cond_t)
|
|
nsz |
d7c151 |
T(pthread_condattr_t)
|
|
nsz |
d7c151 |
T(pthread_key_t)
|
|
nsz |
d7c151 |
T(pthread_mutex_t)
|
|
nsz |
d7c151 |
T(pthread_mutexattr_t)
|
|
nsz |
d7c151 |
T(pthread_once_t)
|
|
nsz |
d7c151 |
T(pthread_rwlock_t)
|
|
nsz |
d7c151 |
T(pthread_rwlockattr_t)
|
|
nsz |
d7c151 |
T(pthread_spinlock_t)
|
|
nsz |
d7c151 |
T(pthread_t)
|
|
nsz |
d7c151 |
C(PTHREAD_BARRIER_SERIAL_THREAD)
|
|
nsz |
d7c151 |
C(PTHREAD_CANCEL_ASYNCHRONOUS)
|
|
nsz |
d7c151 |
C(PTHREAD_CANCEL_ENABLE)
|
|
nsz |
d7c151 |
C(PTHREAD_CANCEL_DEFERRED)
|
|
nsz |
d7c151 |
C(PTHREAD_CANCEL_DISABLE)
|
|
nsz |
d7c151 |
{void *x = PTHREAD_CANCELED;}
|
|
nsz |
d7c151 |
C(PTHREAD_CREATE_DETACHED)
|
|
nsz |
d7c151 |
C(PTHREAD_CREATE_JOINABLE)
|
|
nsz |
d7c151 |
C(PTHREAD_EXPLICIT_SCHED)
|
|
nsz |
d7c151 |
C(PTHREAD_INHERIT_SCHED)
|
|
nsz |
d7c151 |
C(PTHREAD_MUTEX_DEFAULT)
|
|
nsz |
d7c151 |
C(PTHREAD_MUTEX_ERRORCHECK)
|
|
nsz |
d7c151 |
C(PTHREAD_MUTEX_NORMAL)
|
|
nsz |
d7c151 |
C(PTHREAD_MUTEX_RECURSIVE)
|
|
nsz |
d7c151 |
C(PTHREAD_MUTEX_ROBUST)
|
|
nsz |
d7c151 |
C(PTHREAD_MUTEX_STALLED)
|
|
nsz |
d7c151 |
C(PTHREAD_ONCE_INIT)
|
|
nsz |
d7c151 |
C(PTHREAD_PRIO_INHERIT)
|
|
nsz |
d7c151 |
C(PTHREAD_PRIO_NONE)
|
|
nsz |
d7c151 |
C(PTHREAD_PRIO_PROTECT)
|
|
nsz |
d7c151 |
C(PTHREAD_PROCESS_SHARED)
|
|
nsz |
d7c151 |
C(PTHREAD_PROCESS_PRIVATE)
|
|
nsz |
d7c151 |
C(PTHREAD_SCOPE_PROCESS)
|
|
nsz |
d7c151 |
C(PTHREAD_SCOPE_SYSTEM)
|
|
nsz |
d7c151 |
{pthread_cond_t x = PTHREAD_COND_INITIALIZER;}
|
|
nsz |
d7c151 |
{pthread_mutex_t x = PTHREAD_MUTEX_INITIALIZER;}
|
|
nsz |
d7c151 |
{pthread_rwlock_t x = PTHREAD_RWLOCK_INITIALIZER;}
|
|
nsz |
d7c151 |
int(*p_pthread_atfork)(void(*)(void),void(*)(void),void(*)(void)) = pthread_atfork;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_destroy)(pthread_attr_t*) = pthread_attr_destroy;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_getdetachstate)(const pthread_attr_t*,int*) = pthread_attr_getdetachstate;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_getguardsize)(const pthread_attr_t*restrict,size_t*restrict) = pthread_attr_getguardsize;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_getinheritsched)(const pthread_attr_t*restrict,int*restrict) = pthread_attr_getinheritsched;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_getschedparam)(const pthread_attr_t*restrict,struct sched_param*restrict) = pthread_attr_getschedparam;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_getschedpolicy)(const pthread_attr_t*restrict,int*restrict) = pthread_attr_getschedpolicy;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_getscope)(const pthread_attr_t*restrict,int*restrict) = pthread_attr_getscope;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_getstack)(const pthread_attr_t*restrict,void**restrict,size_t*restrict) = pthread_attr_getstack;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_getstacksize)(const pthread_attr_t*restrict,size_t*restrict) = pthread_attr_getstacksize;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_init)(pthread_attr_t*) = pthread_attr_init;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_setdetachstate)(pthread_attr_t*,int) = pthread_attr_setdetachstate;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_setguardsize)(pthread_attr_t*,size_t) = pthread_attr_setguardsize;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_setinheritsched)(pthread_attr_t*,int) = pthread_attr_setinheritsched;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_setschedparam)(pthread_attr_t*restrict,const struct sched_param*restrict) = pthread_attr_setschedparam;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_setschedpolicy)(pthread_attr_t*,int) = pthread_attr_setschedpolicy;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_setscope)(pthread_attr_t*,int) = pthread_attr_setscope;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_setstack)(pthread_attr_t*,void*,size_t) = pthread_attr_setstack;
|
|
nsz |
d7c151 |
int(*p_pthread_attr_setstacksize)(pthread_attr_t*,size_t) = pthread_attr_setstacksize;
|
|
nsz |
d7c151 |
int(*p_pthread_barrier_destroy)(pthread_barrier_t*) = pthread_barrier_destroy;
|
|
nsz |
d7c151 |
int(*p_pthread_barrier_init)(pthread_barrier_t*restrict,const pthread_barrierattr_t*restrict,unsigned) = pthread_barrier_init;
|
|
nsz |
d7c151 |
int(*p_pthread_barrier_wait)(pthread_barrier_t*) = pthread_barrier_wait;
|
|
nsz |
d7c151 |
int(*p_pthread_barrierattr_destroy)(pthread_barrierattr_t*) = pthread_barrierattr_destroy;
|
|
nsz |
d7c151 |
int(*p_pthread_barrierattr_getpshared)(const pthread_barrierattr_t*restrict,int*restrict) = pthread_barrierattr_getpshared;
|
|
nsz |
d7c151 |
int(*p_pthread_barrierattr_init)(pthread_barrierattr_t*) = pthread_barrierattr_init;
|
|
nsz |
d7c151 |
int(*p_pthread_barrierattr_setpshared)(pthread_barrierattr_t*,int) = pthread_barrierattr_setpshared;
|
|
nsz |
d7c151 |
int(*p_pthread_cancel)(pthread_t) = pthread_cancel;
|
|
nsz |
d7c151 |
void(*p_pthread_cleanup_pop)(int) = pthread_cleanup_pop;
|
|
nsz |
d7c151 |
void(*p_pthread_cleanup_push)(void(*)(void*),void*) = pthread_cleanup_push;
|
|
nsz |
d7c151 |
int(*p_pthread_cond_broadcast)(pthread_cond_t*) = pthread_cond_broadcast;
|
|
nsz |
d7c151 |
int(*p_pthread_cond_destroy)(pthread_cond_t*) = pthread_cond_destroy;
|
|
nsz |
d7c151 |
int(*p_pthread_cond_init)(pthread_cond_t*restrict,const pthread_condattr_t*restrict) = pthread_cond_init;
|
|
nsz |
d7c151 |
int(*p_pthread_cond_signal)(pthread_cond_t*) = pthread_cond_signal;
|
|
nsz |
d7c151 |
int(*p_pthread_cond_timedwait)(pthread_cond_t*restrict,pthread_mutex_t*restrict,const struct timespec*restrict) = pthread_cond_timedwait;
|
|
nsz |
d7c151 |
int(*p_pthread_cond_wait)(pthread_cond_t*restrict,pthread_mutex_t*restrict) = pthread_cond_wait;
|
|
nsz |
d7c151 |
int(*p_pthread_condattr_destroy)(pthread_condattr_t*) = pthread_condattr_destroy;
|
|
nsz |
d7c151 |
int(*p_pthread_condattr_getclock)(const pthread_condattr_t*restrict,clockid_t*restrict) = pthread_condattr_getclock;
|
|
nsz |
d7c151 |
int(*p_pthread_condattr_getpshared)(const pthread_condattr_t*restrict,int*restrict) = pthread_condattr_getpshared;
|
|
nsz |
d7c151 |
int(*p_pthread_condattr_init)(pthread_condattr_t*) = pthread_condattr_init;
|
|
nsz |
d7c151 |
int(*p_pthread_condattr_setclock)(pthread_condattr_t*,clockid_t) = pthread_condattr_setclock;
|
|
nsz |
d7c151 |
int(*p_pthread_condattr_setpshared)(pthread_condattr_t*,int) = pthread_condattr_setpshared;
|
|
nsz |
d7c151 |
int(*p_pthread_create)(pthread_t*restrict,const pthread_attr_t*restrict,void*(*)(void*),void*restrict) = pthread_create;
|
|
nsz |
d7c151 |
int(*p_pthread_detach)(pthread_t) = pthread_detach;
|
|
nsz |
d7c151 |
int(*p_pthread_equal)(pthread_t,pthread_t) = pthread_equal;
|
|
nsz |
d7c151 |
void(*p_pthread_exit)(void*) = pthread_exit;
|
|
nsz |
d7c151 |
int(*p_pthread_getschedparam)(pthread_t,int*restrict,struct sched_param*restrict) = pthread_getschedparam;
|
|
nsz |
d7c151 |
void*(*p_pthread_getspecific)(pthread_key_t) = pthread_getspecific;
|
|
nsz |
d7c151 |
int(*p_pthread_join)(pthread_t,void**) = pthread_join;
|
|
nsz |
d7c151 |
int(*p_pthread_key_create)(pthread_key_t*,void(*)(void*)) = pthread_key_create;
|
|
nsz |
d7c151 |
int(*p_pthread_key_delete)(pthread_key_t) = pthread_key_delete;
|
|
nsz |
d7c151 |
int(*p_pthread_mutex_consistent)(pthread_mutex_t*) = pthread_mutex_consistent;
|
|
nsz |
d7c151 |
int(*p_pthread_mutex_destroy)(pthread_mutex_t*) = pthread_mutex_destroy;
|
|
nsz |
d7c151 |
int(*p_pthread_mutex_getprioceiling)(const pthread_mutex_t*restrict,int*restrict) = pthread_mutex_getprioceiling;
|
|
nsz |
d7c151 |
int(*p_pthread_mutex_init)(pthread_mutex_t*restrict,const pthread_mutexattr_t*restrict) = pthread_mutex_init;
|
|
nsz |
d7c151 |
int(*p_pthread_mutex_lock)(pthread_mutex_t*) = pthread_mutex_lock;
|
|
nsz |
d7c151 |
int(*p_pthread_mutex_setprioceiling)(pthread_mutex_t*restrict,int,int*restrict) = pthread_mutex_setprioceiling;
|
|
nsz |
d7c151 |
int(*p_pthread_mutex_trylock)(pthread_mutex_t*) = pthread_mutex_trylock;
|
|
nsz |
d7c151 |
int(*p_pthread_mutex_unlock)(pthread_mutex_t*) = pthread_mutex_unlock;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_destroy)(pthread_mutexattr_t*) = pthread_mutexattr_destroy;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_getprioceiling)(const pthread_mutexattr_t*restrict,int*restrict) = pthread_mutexattr_getprioceiling;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_getprotocol)(const pthread_mutexattr_t*restrict,int*restrict) = pthread_mutexattr_getprotocol;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_getpshared)(const pthread_mutexattr_t*restrict,int*restrict) = pthread_mutexattr_getpshared;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_getrobust)(const pthread_mutexattr_t*restrict,int*restrict) = pthread_mutexattr_getrobust;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_gettype)(const pthread_mutexattr_t*restrict,int*restrict) = pthread_mutexattr_gettype;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_init)(pthread_mutexattr_t*) = pthread_mutexattr_init;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_setprioceiling)(pthread_mutexattr_t*,int) = pthread_mutexattr_setprioceiling;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_setprotocol)(pthread_mutexattr_t*,int) = pthread_mutexattr_setprotocol;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_setpshared)(pthread_mutexattr_t*,int) = pthread_mutexattr_setpshared;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_setrobust)(pthread_mutexattr_t*,int) = pthread_mutexattr_setrobust;
|
|
nsz |
d7c151 |
int(*p_pthread_mutexattr_settype)(pthread_mutexattr_t*,int) = pthread_mutexattr_settype;
|
|
nsz |
d7c151 |
int(*p_pthread_once)(pthread_once_t*,void(*)(void)) = pthread_once;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlock_destroy)(pthread_rwlock_t*) = pthread_rwlock_destroy;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlock_init)(pthread_rwlock_t*restrict,const pthread_rwlockattr_t*restrict) = pthread_rwlock_init;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlock_rdlock)(pthread_rwlock_t*) = pthread_rwlock_rdlock;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlock_tryrdlock)(pthread_rwlock_t*) = pthread_rwlock_tryrdlock;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlock_trywrlock)(pthread_rwlock_t*) = pthread_rwlock_trywrlock;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlock_unlock)(pthread_rwlock_t*) = pthread_rwlock_unlock;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlock_wrlock)(pthread_rwlock_t*) = pthread_rwlock_wrlock;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlockattr_destroy)(pthread_rwlockattr_t*) = pthread_rwlockattr_destroy;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlockattr_getpshared)(const pthread_rwlockattr_t*restrict,int*restrict) = pthread_rwlockattr_getpshared;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlockattr_init)(pthread_rwlockattr_t*) = pthread_rwlockattr_init;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlockattr_setpshared)(pthread_rwlockattr_t*,int) = pthread_rwlockattr_setpshared;
|
|
nsz |
d7c151 |
pthread_t(*p_pthread_self)(void) = pthread_self;
|
|
nsz |
d7c151 |
int(*p_pthread_setcancelstate)(int,int*) = pthread_setcancelstate;
|
|
nsz |
d7c151 |
int(*p_pthread_setcanceltype)(int,int*) = pthread_setcanceltype;
|
|
nsz |
d7c151 |
int(*p_pthread_setschedparam)(pthread_t,int,const struct sched_param*) = pthread_setschedparam;
|
|
nsz |
d7c151 |
int(*p_pthread_setschedprio)(pthread_t,int) = pthread_setschedprio;
|
|
nsz |
d7c151 |
int(*p_pthread_setspecific)(pthread_key_t,const void*) = pthread_setspecific;
|
|
nsz |
d7c151 |
int(*p_pthread_spin_destroy)(pthread_spinlock_t*) = pthread_spin_destroy;
|
|
nsz |
d7c151 |
int(*p_pthread_spin_init)(pthread_spinlock_t*,int) = pthread_spin_init;
|
|
nsz |
d7c151 |
int(*p_pthread_spin_lock)(pthread_spinlock_t*) = pthread_spin_lock;
|
|
nsz |
d7c151 |
int(*p_pthread_spin_trylock)(pthread_spinlock_t*) = pthread_spin_trylock;
|
|
nsz |
d7c151 |
int(*p_pthread_spin_unlock)(pthread_spinlock_t*) = pthread_spin_unlock;
|
|
nsz |
d7c151 |
void(*p_pthread_testcancel)(void) = pthread_testcancel;
|
|
nsz |
b80923 |
}
|
|
nsz |
d7c151 |
#include <time.h>
|
|
nsz |
b80923 |
static void g()
|
|
nsz |
b80923 |
{
|
|
nsz |
d7c151 |
int(*p_pthread_getcpuclockid)(pthread_t,clockid_t*) = pthread_getcpuclockid;
|
|
nsz |
d7c151 |
int(*p_pthread_mutex_timedlock)(pthread_mutex_t*restrict,const struct timespec*restrict) = pthread_mutex_timedlock;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlock_timedrdlock)(pthread_rwlock_t*restrict,const struct timespec*restrict) = pthread_rwlock_timedrdlock;
|
|
nsz |
d7c151 |
int(*p_pthread_rwlock_timedwrlock)(pthread_rwlock_t*restrict,const struct timespec*restrict) = pthread_rwlock_timedwrlock;
|
|
nsz |
d7c151 |
}
|