Lines Matching refs:ts
132 struct timespec ts;
133 ts.tv_sec = abs_timeout / (1000*1000*1000);
134 ts.tv_nsec = abs_timeout % (1000*1000*1000);
143 int r = futex_wait(&fence->val, 2, timeout ? &ts : NULL);
200 struct timespec ts;
203 timespec_get(&ts, TIME_UTC);
205 clock_gettime(CLOCK_REALTIME, &ts);
208 ts.tv_sec += abs_timeout / (1000*1000*1000);
209 ts.tv_nsec += abs_timeout % (1000*1000*1000);
210 if (ts.tv_nsec >= (1000*1000*1000)) {
211 ts.tv_sec++;
212 ts.tv_nsec -= (1000*1000*1000);
217 if (cnd_timedwait(&fence->cond, &fence->mutex, &ts) != thrd_success)