Lines Matching refs:ts
465 timespec ts; in TEST() local
466 ASSERT_EQ(0, clock_gettime(c, &ts)); in TEST()
776 timespec ts; in TEST() local
777 ASSERT_EQ(0, clock_gettime(CLOCK_REALTIME, &ts)); in TEST()
778 ts.tv_sec += 1; in TEST()
780 return pthread_rwlock_timedwrlock(lock, &ts); in TEST()
812 timespec ts; in TEST() local
813 ASSERT_EQ(0, clock_gettime(CLOCK_REALTIME, &ts)); in TEST()
814 ts.tv_sec += 1; in TEST()
816 return pthread_rwlock_timedrdlock(lock, &ts); in TEST()
827 timespec ts; in pthread_rwlock_wakeup_timeout_helper() local
828 ASSERT_EQ(0, clock_gettime(CLOCK_REALTIME, &ts)); in pthread_rwlock_wakeup_timeout_helper()
829 ASSERT_EQ(ETIMEDOUT, arg->timed_lock_function(&arg->lock, &ts)); in pthread_rwlock_wakeup_timeout_helper()
830 ts.tv_nsec = -1; in pthread_rwlock_wakeup_timeout_helper()
831 ASSERT_EQ(EINVAL, arg->timed_lock_function(&arg->lock, &ts)); in pthread_rwlock_wakeup_timeout_helper()
832 ts.tv_nsec = NS_PER_S; in pthread_rwlock_wakeup_timeout_helper()
833 ASSERT_EQ(EINVAL, arg->timed_lock_function(&arg->lock, &ts)); in pthread_rwlock_wakeup_timeout_helper()
834 ts.tv_nsec = NS_PER_S - 1; in pthread_rwlock_wakeup_timeout_helper()
835 ts.tv_sec = -1; in pthread_rwlock_wakeup_timeout_helper()
836 ASSERT_EQ(ETIMEDOUT, arg->timed_lock_function(&arg->lock, &ts)); in pthread_rwlock_wakeup_timeout_helper()
837 ASSERT_EQ(0, clock_gettime(CLOCK_REALTIME, &ts)); in pthread_rwlock_wakeup_timeout_helper()
838 ts.tv_sec += 1; in pthread_rwlock_wakeup_timeout_helper()
839 ASSERT_EQ(ETIMEDOUT, arg->timed_lock_function(&arg->lock, &ts)); in pthread_rwlock_wakeup_timeout_helper()
1194 timespec ts; in TEST_F() local
1195 ASSERT_EQ(0, clock_gettime(CLOCK_REALTIME, &ts)); in TEST_F()
1196 ts.tv_sec += 1; in TEST_F()
1198 return pthread_cond_timedwait(cond, mutex, &ts); in TEST_F()
1206 timespec ts; in TEST_F() local
1207 ASSERT_EQ(0, clock_gettime(CLOCK_MONOTONIC, &ts)); in TEST_F()
1208 ts.tv_sec += 1; in TEST_F()
1210 return pthread_cond_timedwait(cond, mutex, &ts); in TEST_F()
1222 timespec ts; in TEST() local
1223 ASSERT_EQ(0, clock_gettime(CLOCK_REALTIME, &ts)); in TEST()
1224 ASSERT_EQ(ETIMEDOUT, pthread_cond_timedwait(&cond, &mutex, &ts)); in TEST()
1225 ts.tv_nsec = -1; in TEST()
1226 ASSERT_EQ(EINVAL, pthread_cond_timedwait(&cond, &mutex, &ts)); in TEST()
1227 ts.tv_nsec = NS_PER_S; in TEST()
1228 ASSERT_EQ(EINVAL, pthread_cond_timedwait(&cond, &mutex, &ts)); in TEST()
1229 ts.tv_nsec = NS_PER_S - 1; in TEST()
1230 ts.tv_sec = -1; in TEST()
1231 ASSERT_EQ(ETIMEDOUT, pthread_cond_timedwait(&cond, &mutex, &ts)); in TEST()
1673 timespec ts; in TEST() local
1674 ASSERT_EQ(0, clock_gettime(CLOCK_REALTIME, &ts)); in TEST()
1675 ASSERT_EQ(ETIMEDOUT, pthread_mutex_timedlock(&m, &ts)); in TEST()
1676 ts.tv_nsec = -1; in TEST()
1677 ASSERT_EQ(EINVAL, pthread_mutex_timedlock(&m, &ts)); in TEST()
1678 ts.tv_nsec = NS_PER_S; in TEST()
1679 ASSERT_EQ(EINVAL, pthread_mutex_timedlock(&m, &ts)); in TEST()
1680 ts.tv_nsec = NS_PER_S - 1; in TEST()
1681 ts.tv_sec = -1; in TEST()
1682 ASSERT_EQ(ETIMEDOUT, pthread_mutex_timedlock(&m, &ts)); in TEST()
1687 ASSERT_EQ(0, clock_gettime(CLOCK_REALTIME, &ts)); in TEST()
1688 ts.tv_sec += 1; in TEST()
1689 ASSERT_EQ(0, pthread_mutex_timedlock(&m, &ts)); in TEST()