Lines Matching refs:thread
609 thread_spawn(thread_id_t *thread, void *(fn)(void *), void *arg) {
613 &thread->tid,
620 printf("created pthread %p\n", thread->tid);
622 thread->pid = fork();
623 if (thread->pid == 0) {
630 printf("forked pid %d\n", thread->pid);
635 thread_join(thread_id_t *thread) {
639 printf("joining thread %p\n", thread->tid);
640 ret = pthread_join(thread->tid, NULL);
642 err(1, "pthread_join(%p)", thread->tid);
646 printf("waiting for pid %d\n", thread->pid);
647 waitpid(thread->pid, &stat, 0);