Lines Matching refs:thread
51 pthread_t thread; member
60 Thread* thread = (Thread*)entryPtr; in startThread() local
61 deThreadFunc func = thread->func; in startThread()
62 void* arg = thread->arg; in startThread()
73 Thread* thread = (Thread*)deCalloc(sizeof(Thread)); in deThread_create() local
75 if (!thread) in deThread_create()
78 thread->func = func; in deThread_create()
79 thread->arg = arg; in deThread_create()
83 deFree(thread); in deThread_create()
93 deFree(thread); in deThread_create()
97 if (pthread_create(&thread->thread, &attr, startThread, thread) != 0) in deThread_create()
100 deFree(thread); in deThread_create()
103 DE_ASSERT(thread->thread); in deThread_create()
107 return (deThread)thread; in deThread_create()
112 Thread* thread = (Thread*)threadptr; in deThread_join() local
115 DE_ASSERT(thread->thread); in deThread_join()
116 ret = pthread_join(thread->thread, DE_NULL); in deThread_join()
120 pthread_detach(thread->thread); in deThread_join()
123 thread->thread = 0; in deThread_join()
130 Thread* thread = (Thread*)threadptr; in deThread_destroy() local
132 if (thread->thread) in deThread_destroy()
135 int ret = pthread_detach(thread->thread); in deThread_destroy()
140 deFree(thread); in deThread_destroy()