Lines Matching defs:curthread
47 testcancel(struct pthread *curthread)
49 if (__predict_false(SHOULD_CANCEL(curthread) &&
50 !THR_IN_CRITICAL(curthread)))
55 _thr_testcancel(struct pthread *curthread)
57 testcancel(curthread);
63 struct pthread *curthread = _get_curthread();
71 if ((ret = _thr_find_thread(curthread, pthread, 1)) == 0) {
77 THR_THREAD_UNLOCK(curthread, pthread);
85 struct pthread *curthread = _get_curthread();
99 oldval = atomic_swap_int(&curthread->cancel_enable, val);
100 if (state == PTHREAD_CANCEL_ENABLE && curthread->cancel_async)
101 testcancel(curthread);
112 struct pthread *curthread = _get_curthread();
115 oldval = curthread->cancel_async;
118 curthread->cancel_async = 1;
119 testcancel(curthread);
122 curthread->cancel_async = 0;
138 struct pthread *curthread;
141 curthread = _get_curthread();
142 testcancel(curthread);
146 _thr_cancel_enter(struct pthread *curthread)
148 curthread->cancel_point = 1;
149 testcancel(curthread);
153 _thr_cancel_enter2(struct pthread *curthread, int maycancel)
155 curthread->cancel_point = 1;
156 if (__predict_false(SHOULD_CANCEL(curthread) &&
157 !THR_IN_CRITICAL(curthread))) {
159 thr_wake(curthread->tid);
166 _thr_cancel_leave(struct pthread *curthread, int maycancel)
168 curthread->cancel_point = 0;
170 testcancel(curthread);