/glibc-2.36/include/ |
D | time.h | 259 extern int __settimeofday64 (const struct __timeval64 *tv, 262 extern int __gettimeofday64 (struct __timeval64 *restrict tv, 357 valid_timeval_to_timespec64 (const struct timeval tv) in valid_timeval_to_timespec64() argument 361 ts64.tv_sec = tv.tv_sec; in valid_timeval_to_timespec64() 362 ts64.tv_nsec = tv.tv_usec * 1000; in valid_timeval_to_timespec64() 369 valid_timeval_to_timeval64 (const struct timeval tv) in valid_timeval_to_timeval64() argument 373 tv64.tv_sec = tv.tv_sec; in valid_timeval_to_timeval64() 374 tv64.tv_usec = tv.tv_usec; in valid_timeval_to_timeval64() 384 struct timeval tv; in valid_timeval64_to_timeval() local 386 tv.tv_sec = (time_t) tv64.tv_sec; in valid_timeval64_to_timeval() [all …]
|
D | random-bits.h | 33 struct __timespec64 tv; in random_bits() local 34 __clock_gettime64 (CLOCK_MONOTONIC, &tv); in random_bits() 36 uint32_t ret = tv.tv_nsec ^ tv.tv_sec; in random_bits()
|
/glibc-2.36/sunrpc/ |
D | clnt_gen.c | 55 struct timeval tv; in clnt_create() local 75 tv.tv_sec = 25; in clnt_create() 76 tv.tv_usec = 0; in clnt_create() 77 clnt_control (client, CLSET_TIMEOUT, (char *)&tv); in clnt_create() 107 tv.tv_sec = 5; in clnt_create() 108 tv.tv_usec = 0; in clnt_create() 109 client = clntudp_create (&sin, prog, vers, tv, &sock); in clnt_create() 118 tv.tv_sec = 25; in clnt_create() 119 clnt_control (client, CLSET_TIMEOUT, (char *)&tv); in clnt_create() 132 tv.tv_sec = 25; in clnt_create() [all …]
|
/glibc-2.36/sysdeps/generic/ |
D | hp-timing.h | 37 struct timespec tv; \ 38 clock_gettime (CLOCK_MONOTONIC, &tv); \ 39 (var) = (tv.tv_nsec + UINT64_C(1000000000) * tv.tv_sec); \ 44 struct __timespec64 tv; \ 45 __clock_gettime64 (CLOCK_MONOTONIC, &tv); \ 46 (var) = (tv.tv_nsec + UINT64_C(1000000000) * tv.tv_sec); \
|
/glibc-2.36/sysdeps/unix/sysv/linux/ |
D | gettimeofday.c | 32 __gettimeofday_syscall (struct timeval *restrict tv, void *restrict tz) in __gettimeofday_syscall() argument 36 return INLINE_SYSCALL_CALL (gettimeofday, tv, tz); in __gettimeofday_syscall() 48 __gettimeofday (struct timeval *restrict tv, void *restrict tz) 53 return INLINE_VSYSCALL (gettimeofday, 2, tv, tz); 63 __gettimeofday64 (struct __timeval64 *restrict tv, void *restrict tz) 72 *tv = timespec64_to_timeval64 (ts64); 80 __gettimeofday (struct timeval *restrict tv, void *restrict tz) 92 *tv = valid_timeval64_to_timeval (tv64);
|
D | settimeofday.c | 26 __settimeofday64 (const struct __timeval64 *tv, const struct timezone *tz) in __settimeofday64() argument 31 if (tv != 0) in __settimeofday64() 39 struct __timespec64 ts = timeval64_to_timespec64 (*tv); in __settimeofday64() 47 __settimeofday (const struct timeval *tv, const struct timezone *tz) in libc_hidden_def() 49 if (__glibc_unlikely (tv == NULL)) in libc_hidden_def() 53 struct __timeval64 tv64 = valid_timeval_to_timeval64 (*tv); in libc_hidden_def()
|
D | tst-socket-timestamp.c | 117 struct timeval tv; in do_recvmsg_slack_ancillary() local 118 memcpy (&tv, CMSG_DATA (cmsg), sizeof (tv)); in do_recvmsg_slack_ancillary() 120 printf ("SCM_TIMESTAMP: {%jd, %jd}\n", (intmax_t)tv.tv_sec, in do_recvmsg_slack_ancillary() 121 (intmax_t)tv.tv_usec); in do_recvmsg_slack_ancillary() 260 struct timeval tv; in do_recvmsg_multiple_ancillary() local 261 memcpy (&tv, CMSG_DATA (cmsg), sizeof (tv)); in do_recvmsg_multiple_ancillary() 263 printf ("SCM_TIMESTAMP: {%jd, %jd}\n", (intmax_t)tv.tv_sec, in do_recvmsg_multiple_ancillary() 264 (intmax_t)tv.tv_usec); in do_recvmsg_multiple_ancillary()
|
/glibc-2.36/gmon/ |
D | tst-sprofil.c | 61 struct timeval tv, start; in main() local 126 if (sprofil (prof, profcnt, &tv, PROF_UINT) < 0) in main() 134 t_tick = tv.tv_sec + 1e-6 * tv.tv_usec; in main() 143 gettimeofday (&tv, NULL); in main() 144 timersub (&tv, &start, &tv); in main() 145 delta = tv.tv_sec + 1e-6 * tv.tv_usec; in main()
|
/glibc-2.36/io/ |
D | tst-futimesat.c | 129 struct timeval tv[2]; in do_test() local 130 tv[0].tv_sec = st1.st_atime + 1; in do_test() 131 tv[0].tv_usec = 0; in do_test() 132 tv[1].tv_sec = st1.st_mtime + 1; in do_test() 133 tv[1].tv_usec = 0; in do_test() 134 if (futimesat (dir_fd, "some-file", tv) != 0) in do_test() 147 if (st2.st_mtime != tv[1].tv_sec in do_test()
|
D | tst-utimes.c | 30 test_utimes_helper (const char *file, int fd, const struct timeval *tv) in test_utimes_helper() argument 32 int result = utimes (file, tv); in test_utimes_helper() 39 TEST_COMPARE (st.st_atime, tv[0].tv_sec); in test_utimes_helper() 42 TEST_COMPARE (st.st_mtime, tv[1].tv_sec); in test_utimes_helper()
|
D | tst-futimes.c | 29 test_futimens_helper (const char *file, int fd, const struct timeval *tv) in test_futimens_helper() argument 31 int r = futimes (fd, tv); in test_futimens_helper() 38 TEST_COMPARE (st.st_atime, tv[0].tv_sec); in test_futimens_helper() 41 TEST_COMPARE (st.st_mtime, tv[1].tv_sec); in test_futimens_helper()
|
D | tst-lutimes.c | 30 const struct timeval *tv) in test_lutimes_helper() argument 35 TEST_VERIFY_EXIT (lutimes (testlink, tv) == 0); in test_lutimes_helper() 40 TEST_COMPARE (stlink.st_atime, tv[0].tv_sec); in test_lutimes_helper() 41 TEST_COMPARE (stlink.st_mtime, tv[1].tv_sec); in test_lutimes_helper()
|
/glibc-2.36/sysdeps/mach/hurd/ |
D | setitimer.c | 41 quantize_timeval (struct timeval *tv) in quantize_timeval() argument 48 tv->tv_usec = ((tv->tv_usec + (quantum - 1)) / quantum) * quantum; in quantize_timeval() 49 if (tv->tv_usec >= 1000000) in quantize_timeval() 51 ++tv->tv_sec; in quantize_timeval() 52 tv->tv_usec -= 1000000; in quantize_timeval() 249 time_value_t tv; in setitimer_locked() local 250 __host_get_time (__mach_host_self (), &tv); in setitimer_locked() 251 now.tv_sec = tv.seconds; in setitimer_locked() 252 now.tv_usec = tv.microseconds; in setitimer_locked()
|
D | getitimer.c | 66 time_value_t tv; in __getitimer() local 67 __host_get_time (__mach_host_self (), &tv); in __getitimer() 68 elapsed.tv_sec = tv.seconds; in __getitimer() 69 elapsed.tv_usec = tv.microseconds; in __getitimer()
|
/glibc-2.36/sysdeps/pthread/ |
D | tst-cond9.c | 48 struct timeval tv; in tf() local 49 (void) gettimeofday (&tv, NULL); in tf() 52 TIMEVAL_TO_TIMESPEC (&tv, &ts); in tf() 95 struct timeval tv; in do_test() local 96 (void) gettimeofday (&tv, NULL); in do_test() 99 TIMEVAL_TO_TIMESPEC (&tv, &ts); in do_test()
|
D | tst-robust3.c | 10 struct timeval tv; \ 11 gettimeofday (&tv, NULL); \ 14 tmo.tv_sec = tv.tv_sec + 3600; \
|
D | tst-sem10.c | 37 struct timeval tv; in do_test() local 38 if (gettimeofday (&tv, NULL) != 0) in do_test() 45 TIMEVAL_TO_TIMESPEC (&tv, &ts); in do_test()
|
D | tst-cond20.c | 44 struct timeval tv; in tf() local 45 gettimeofday (&tv, NULL); in tf() 48 ts.tv_sec = tv.tv_sec + 3; in tf() 49 ts.tv_nsec = tv.tv_usec * 1000; in tf()
|
/glibc-2.36/inet/ |
D | net-internal.h | 140 struct timeval tv) attribute_hidden; 152 __is_timeval_valid_timeout (struct timeval tv) in __is_timeval_valid_timeout() argument 154 return tv.tv_sec >= 0 && tv.tv_usec >= 0 && tv.tv_usec < 1000 * 1000; in __is_timeval_valid_timeout()
|
D | deadline.c | 47 struct timeval tv) in __deadline_from_timeval() argument 49 assert (__is_timeval_valid_timeout (tv)); in __deadline_from_timeval() 54 sec += tv.tv_sec; in __deadline_from_timeval() 55 if (sec < (uintmax_t) tv.tv_sec) in __deadline_from_timeval() 59 int nsec = current.current.tv_nsec + tv.tv_usec * 1000; in __deadline_from_timeval()
|
/glibc-2.36/time/sys/ |
D | time.h | 38 # define TIMEVAL_TO_TIMESPEC(tv, ts) { \ argument 39 (ts)->tv_sec = (tv)->tv_sec; \ 40 (ts)->tv_nsec = (tv)->tv_usec * 1000; \ 42 # define TIMESPEC_TO_TIMEVAL(tv, ts) { \ argument 43 (tv)->tv_sec = (ts)->tv_sec; \ 44 (tv)->tv_usec = (ts)->tv_nsec / 1000; \
|
/glibc-2.36/nptl/ |
D | tst-sem12.c | 7 struct timeval tv; \ 8 gettimeofday (&tv, NULL); \ 9 TIMEVAL_TO_TIMESPEC (&tv, &ts); \
|
/glibc-2.36/time/ |
D | tst-clock_settime.c | 29 const struct timespec tv = { FUTURE_TIME, 0}; in do_test() local 33 xclock_settime(CLOCK_REALTIME, &tv); in do_test() 39 if (tv_future.tv_sec < tv.tv_sec) in do_test()
|
D | settimeofday.c | 25 __settimeofday (const struct timeval *tv, const struct timezone *tz) in __settimeofday() argument 29 if (tv != 0) in __settimeofday() 38 TIMEVAL_TO_TIMESPEC (tv, &ts); in __settimeofday()
|
D | tst-settimeofday.c | 31 const struct timeval tv = { FUTURE_TIME, 0}; in do_test() local 40 int ret = settimeofday (&tv, NULL); in do_test() 49 if (tv_future.tv_sec < tv.tv_sec) in do_test()
|