/bionic/libc/upstream-netbsd/lib/libc/isc/ |
D | ev_timers.c | 78 x.tv_nsec = nsec; in evConsTime() 87 x.tv_nsec = addend1.tv_nsec + addend2.tv_nsec; in evAddTime() 88 if (x.tv_nsec >= BILLION) { in evAddTime() 90 x.tv_nsec -= BILLION; in evAddTime() 100 if (minuend.tv_nsec >= subtrahend.tv_nsec) in evSubTime() 101 x.tv_nsec = minuend.tv_nsec - subtrahend.tv_nsec; in evSubTime() 103 x.tv_nsec = BILLION - subtrahend.tv_nsec + minuend.tv_nsec; in evSubTime() 118 n = a.tv_nsec - b.tv_nsec; in evCmpTime() 171 ts.tv_nsec = tv.tv_usec * 1000; in evTimeSpec() 180 tv.tv_usec = (suseconds_t)(ts.tv_nsec / 1000); in evTimeVal() [all …]
|
/bionic/libc/bionic/ |
D | bionic_time_conversions.cpp | 41 ts.tv_nsec = tv.tv_usec * 1000; in timespec_from_timeval() 47 ts.tv_nsec = (ms % 1000) * 1000000; in timespec_from_ms() 52 tv.tv_usec = ts.tv_nsec / 1000; in timeval_from_timespec() 63 monotonic_time.tv_nsec -= cur_realtime_time.tv_nsec; in monotonic_time_from_realtime_time() 64 monotonic_time.tv_nsec += cur_monotonic_time.tv_nsec; in monotonic_time_from_realtime_time() 65 if (monotonic_time.tv_nsec >= NS_PER_S) { in monotonic_time_from_realtime_time() 66 monotonic_time.tv_nsec -= NS_PER_S; in monotonic_time_from_realtime_time() 68 } else if (monotonic_time.tv_nsec < 0) { in monotonic_time_from_realtime_time() 69 monotonic_time.tv_nsec += NS_PER_S; in monotonic_time_from_realtime_time()
|
D | clock.cpp | 39 return (ts.tv_sec * CLOCKS_PER_SEC) + (ts.tv_nsec / (NS_PER_S / CLOCKS_PER_SEC)); in clock()
|
D | usleep.cpp | 36 ts.tv_nsec = (us % 1000000) * 1000; in usleep()
|
/bionic/libc/private/ |
D | bionic_time_conversions.h | 56 if (ts->tv_nsec < 0 || ts->tv_nsec >= NS_PER_S) { in check_timespec() 69 abs_ts.tv_nsec += ts.tv_nsec; in absolute_timespec_from_timespec() 70 if (abs_ts.tv_nsec >= NS_PER_S) { in absolute_timespec_from_timespec() 71 abs_ts.tv_nsec -= NS_PER_S; in absolute_timespec_from_timespec()
|
/bionic/libc/include/sys/ |
D | stat.h | 112 #define st_atimensec st_atim.tv_nsec 113 #define st_mtimensec st_mtim.tv_nsec 114 #define st_ctimensec st_ctim.tv_nsec 116 #define st_atime_nsec st_atim.tv_nsec 117 #define st_mtime_nsec st_mtim.tv_nsec 118 #define st_ctime_nsec st_ctim.tv_nsec
|
D | time.h | 91 (ts)->tv_nsec = (tv)->tv_usec * 1000; \ 95 (tv)->tv_usec = (ts)->tv_nsec / 1000; \
|
/bionic/tests/ |
D | semaphore_test.cpp | 97 ts.tv_nsec += (ms % 1000) * 1000000; in timespec_add_ms() 98 if (ts.tv_nsec >= NS_PER_S) { in timespec_add_ms() 100 ts.tv_nsec -= NS_PER_S; in timespec_add_ms() 119 ts.tv_nsec = -1; in sem_timedwait_helper() 123 ts.tv_nsec = NS_PER_S; in sem_timedwait_helper() 128 ts.tv_nsec = NS_PER_S - 1; in sem_timedwait_helper()
|
D | time_test.cpp | 369 ts.it_value.tv_nsec = value_ns; in SetTime() 371 ts.it_interval.tv_nsec = interval_ns; in SetTime() 423 ts.it_value.tv_nsec = 1; in TEST() 425 ts.it_interval.tv_nsec = 0; in TEST() 643 ts.it_value.tv_nsec = 0; in TEST() 645 ts.it_interval.tv_nsec = 0; in TEST() 671 ts2.tv_nsec -= ts1.tv_nsec; in TEST() 672 if (ts2.tv_nsec < 0) { in TEST() 674 ts2.tv_nsec += NS_PER_S; in TEST() 679 ASSERT_LT(ts2.tv_nsec, 10'000'000); in TEST() [all …]
|
D | poll_test.cpp | 44 timespec ts = { .tv_nsec = 100 }; in TEST() 53 timespec ts = { .tv_nsec = 100 }; in TEST()
|
D | sys_stat_test.cpp | 42 times[0].tv_nsec = 0; in TEST() 44 times[1].tv_nsec = 0; in TEST() 58 times[0].tv_nsec = 0; in TEST() 60 times[1].tv_nsec = 0; in TEST()
|
D | sys_select_test.cpp | 164 tv.tv_nsec = 0; in TEST() 178 ASSERT_EQ(0, tv.tv_nsec); in TEST()
|
D | sys_sem_test.cpp | 61 timespec ts = { .tv_sec = 0, .tv_nsec = 100 }; in TEST()
|
D | threads_test.cpp | 288 timespec ts = { .tv_nsec = 500000 }; in TEST() 408 uint64_t t = remaining.tv_sec * 1000000000 + remaining.tv_nsec; in TEST()
|
D | signal_test.cpp | 723 timespec timeout = { .tv_sec = 2, .tv_nsec = 0 }; in TEST() 744 timespec timeout = { .tv_sec = 2, .tv_nsec = 0 }; in TEST() 761 timespec timeout = { .tv_sec = 0, .tv_nsec = 1000000 }; in TEST()
|
/bionic/libc/kernel/uapi/linux/ |
D | time_types.h | 24 long long tv_nsec; member 32 long tv_nsec; member
|
D | time.h | 27 long tv_nsec; member
|
D | stat.h | 56 __u32 tv_nsec; member
|
/bionic/libc/dns/resolv/ |
D | res_stats.c | 32 long ms0 = t0->tv_sec * 1000 + t0->tv_nsec / 1000000; in _res_stats_calculate_rtt() 33 long ms1 = t1->tv_sec * 1000 + t1->tv_nsec / 1000000; in _res_stats_calculate_rtt()
|
/bionic/libc/include/bits/ |
D | timespec.h | 50 long tv_nsec; member
|
/bionic/libc/async_safe/ |
D | async_safe_log.cpp | 486 uint32_t tv_nsec; member 507 realtime_ts.tv_nsec = ts.tv_nsec; in async_safe_write_log()
|
/bionic/libc/kernel/uapi/linux/hsi/ |
D | cs-protocol.h | 51 __u32 tv_nsec; member
|
/bionic/tests/headers/posix/ |
D | time_h.c | 60 STRUCT_MEMBER(struct timespec, long, tv_nsec); in time_h()
|
/bionic/libc/kernel/uapi/drm/ |
D | msm_drm.h | 34 __s64 tv_nsec; member
|
D | etnaviv_drm.h | 27 __s64 tv_nsec; member
|