Lines Matching defs:pthread
35 #include <pthread.h>
62 static TAILQ_HEAD(, pthread) free_threadq;
69 LIST_HEAD(thread_hash_head, pthread);
74 static void thr_destroy(struct pthread *curthread, struct pthread *thread);
96 _thr_gc(struct pthread *curthread)
98 struct pthread *td, *td_next;
99 TAILQ_HEAD(, pthread) worklist;
131 struct pthread *
132 _thr_alloc(struct pthread *curthread)
134 struct pthread *thread = NULL;
153 thread = __thr_calloc(1, sizeof(struct pthread));
166 __rangeof(struct pthread, _pthread_startzero, _pthread_endzero));
186 _thr_free(struct pthread *curthread, struct pthread *thread)
209 * pthread id is reused too quickly, may help some buggy apps.
219 thr_destroy(struct pthread *curthread __unused, struct pthread *thread)
233 _thr_link(struct pthread *curthread, struct pthread *thread)
245 _thr_unlink(struct pthread *curthread, struct pthread *thread)
254 _thr_hash_add(struct pthread *thread)
263 _thr_hash_remove(struct pthread *thread)
268 struct pthread *
269 _thr_hash_find(struct pthread *thread)
271 struct pthread *td;
288 _thr_ref_add(struct pthread *curthread, struct pthread *thread,
308 _thr_ref_delete(struct pthread *curthread, struct pthread *thread)
318 _thr_try_gc(struct pthread *curthread, struct pthread *thread)
339 _thr_find_thread(struct pthread *curthread, struct pthread *thread,
342 struct pthread *pthread;
350 pthread = _thr_hash_find(thread);
351 if (pthread) {
352 THR_THREAD_LOCK(curthread, pthread);
353 if (include_dead == 0 && pthread->state == PS_DEAD) {
354 THR_THREAD_UNLOCK(curthread, pthread);
379 struct pthread *curthread, *thrd;