Home
last modified time | relevance | path

Searched refs:elapsed (Results 1 – 25 of 107) sorted by relevance

12345

/freebsd/tests/sys/kqueue/libkqueue/
H A Dtimer.c441 long elapsed; in test_update() local
466 elapsed = now() - start; in test_update()
472 printf("timer expired after %ld us\n", elapsed); in test_update()
473 if (elapsed < MS_TO_US(1)) in test_update()
474 errx(1, "early timer expiration: %ld us", elapsed); in test_update()
475 if (elapsed > SEC_TO_US(1)) in test_update()
476 errx(1, "late timer expiration: %ld us", elapsed); in test_update()
486 long elapsed; in test_update_equal() local
512 elapsed = now() - start; in test_update_equal()
518 printf("timer expired after %ld us\n", elapsed); in test_update_equal()
[all …]
/freebsd/contrib/tnftp/src/
H A Dprogressbar.c140 double elapsed; local
253 elapsed = td.tv_sec + (td.tv_usec / 1000000.0);
258 if (elapsed > 0.0)
259 bytespersec /= elapsed;
270 if (bytes <= 0 || elapsed <= 0.0 || cursize > filesize) {
276 ((filesize - restart_point) / (bytes / elapsed) -
277 elapsed);
315 double elapsed; local
327 elapsed = td.tv_sec + (td.tv_usec / 1000000.0);
331 if (elapsed > 0.0)
[all …]
/freebsd/sbin/camcontrol/
H A Dprogress.c91 prog->elapsed = prog->now - prog->start; in progress_update()
92 if (done == 0 || prog->elapsed == 0 || prog->done / prog->elapsed == 0) { in progress_update()
95 prog->eta = prog->size / (prog->done / prog->elapsed) - prog->elapsed; in progress_update()
174 if (prog->elapsed > 0) { in progress_draw()
175 bytespersec /= prog->elapsed; in progress_draw()
181 if (prog->done == 0 || prog->elapsed <= 0 || prog->done > prog->size) { in progress_draw()
/freebsd/tools/regression/posixsem/
H A Dposixsem.c57 #define ELAPSED(elapsed, limit) (abs((elapsed) - (limit)) < 100) argument
786 u_int elapsed; in unlocked_timedwait() local
794 if (timedwait(id, 5000, &elapsed, 0) < 0) { in unlocked_timedwait()
798 if (!ELAPSED(elapsed, 0)) { in unlocked_timedwait()
799 fail_err("ksem_timedwait() of unlocked sem took %ums", elapsed); in unlocked_timedwait()
820 u_int elapsed; in expired_timedwait() local
828 if (timedwait(id, 2500, &elapsed, ETIMEDOUT) < 0) { in expired_timedwait()
832 if (!ELAPSED(elapsed, 2500)) { in expired_timedwait()
835 elapsed); in expired_timedwait()
856 u_int elapsed; in locked_timedwait() local
[all …]
/freebsd/usr.bin/lockf/tests/
H A Dlockf_test.sh162 elapsed=$((now - start))
164 if [ "$elapsed" -lt "$sub_delay" ]; then
231 elapsed=$((end - start))
233 if [ "$elapsed" -gt 5 ]; then
234 atf_fail "lockf seems to have dodged the SIGTERM ($elapsed passed)"
252 elapsed=$((end - start))
254 if [ "$elapsed" -gt 5 ]; then
255 atf_fail "lockf -T seems to have dodged the SIGTERM ($elapsed passed)"
/freebsd/contrib/xz/src/xz/
H A Dmessage.c334 progress_speed(uint64_t uncompressed_pos, uint64_t elapsed) in progress_speed() argument
338 if (elapsed < 3000) in progress_speed()
348 / ((double)(elapsed) * (1024.0 / 1000.0)); in progress_speed()
406 progress_remaining(uint64_t in_pos, uint64_t elapsed) in progress_remaining() argument
417 || in_pos < (UINT64_C(1) << 19) || elapsed < 8000) in progress_remaining()
424 * ((double)(elapsed) / 1000.0) / (double)(in_pos)); in progress_remaining()
531 const uint64_t elapsed = mytime_get_elapsed(); in message_progress_update() local
534 if (progress_next_update > elapsed) in message_progress_update()
537 progress_next_update = elapsed + 1000; in message_progress_update()
559 progress_speed(uncompressed_pos, elapsed), in message_progress_update()
[all …]
/freebsd/tools/test/stress2/tools/
H A Dfast.sh32 log=/tmp/stress2.d/elapsed
33 lst=/tmp/elapsed.lst
34 lst2=/tmp/elapsed.order
35 tim=/tmp/elapsed.tim
/freebsd/tools/tools/net80211/stumbler/
H A Dstumbler.c866 unsigned long elapsed = 0; in elapsed_ms() local
869 elapsed = 1000*1000 - prev->tv_usec + in elapsed_ms()
873 elapsed = now->tv_usec - prev->tv_usec; in elapsed_ms()
875 elapsed /= 1000; //ms in elapsed_ms()
877 elapsed += (now->tv_sec - prev->tv_sec)*1000; in elapsed_ms()
878 return elapsed; in elapsed_ms()
882 unsigned long elapsed = 0; in chanhop() local
888 elapsed = elapsed_ms(tv, &chaninfo.last_hop); in chanhop()
891 if (elapsed >= hopfreq) { in chanhop()
901 elapsed = hopfreq; in chanhop()
[all …]
/freebsd/crypto/openssh/
H A Dprogressmeter.c128 double elapsed, now; in refresh_progress_meter() local
150 elapsed = now - last_update; in refresh_progress_meter()
152 elapsed = now - start; in refresh_progress_meter()
159 if (elapsed != 0) in refresh_progress_meter()
160 cur_speed = (transferred / elapsed); in refresh_progress_meter()
197 stalled += elapsed; in refresh_progress_meter()
209 seconds = elapsed; in refresh_progress_meter()
/freebsd/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/docsExamples/
H A Drwinfo.d42 uint64_t elapsed; member
63 i[probefunc].elapsed += timestamp - i[probefunc].ts;
71 i["read"].maxbytes, i["read"].elapsed);
73 i["write"].maxbytes, i["write"].elapsed);
/freebsd/sys/contrib/openzfs/cmd/raidz_test/
H A Draidz_bench.c76 double elapsed, d_bw; in run_gen_bench_impl() local
104 elapsed = NSEC2SEC((double)(gethrtime() - start)); in run_gen_bench_impl()
108 d_bw /= (1024.0 * 1024.0 * elapsed); in run_gen_bench_impl()
148 double elapsed, d_bw; in run_rec_bench_impl() local
196 elapsed = NSEC2SEC((double)(gethrtime() - start)); in run_rec_bench_impl()
200 d_bw /= (1024.0 * 1024.0 * elapsed); in run_rec_bench_impl()
/freebsd/sys/contrib/openzfs/tests/zfs-tests/cmd/
H A Dmmap_sync.c124 double elapsed = (t2.tv_sec - t1.tv_sec) * 1000.0; in main() local
125 elapsed += ((t2.tv_usec - t1.tv_usec) / 1000.0); in main()
126 if (elapsed > max_msync_time_ms) { in main()
127 fprintf(stderr, "slow msync: %f ms\n", elapsed); in main()
/freebsd/tools/tools/net80211/w00t/assoc/
H A Dassoc.c790 int elapsed = 0; in main() local
795 elapsed = tv.tv_sec - start.tv_sec; in main()
796 if (elapsed == 0) { in main()
797 elapsed = tv.tv_usec - start.tv_usec; in main()
799 elapsed *= (elapsed-1)*1000*1000; in main()
800 elapsed += 1000*1000 - start.tv_usec; in main()
801 elapsed += tv.tv_usec; in main()
803 if (elapsed >= timeout) in main()
811 elapsed = timeout - elapsed; in main()
812 tv.tv_sec = elapsed/1000/1000; in main()
[all …]
/freebsd/sys/contrib/openzfs/module/zfs/
H A Dzfs_ratelimit.c80 hrtime_t elapsed; in zfs_ratelimit() local
86 elapsed = now - rl->start; in zfs_ratelimit()
89 if (NSEC2SEC(elapsed) >= rl->interval) { in zfs_ratelimit()
/freebsd/tools/test/stress2/misc/
H A Dmarcus4.sh79 elapsed=$((`date +%s` - start))
80 if [ $elapsed -gt $((30 * 60)) ]; then
81 echo "Runtime is $elapsed seconds"
/freebsd/contrib/ntp/sntp/libevent/sample/
H A Dtime-test.c47 double elapsed; in timeout_cb() local
51 elapsed = difference.tv_sec + in timeout_cb()
55 (int)newtime.tv_sec, elapsed); in timeout_cb()
/freebsd/contrib/libevent/sample/
H A Dtime-test.c47 double elapsed; in timeout_cb() local
51 elapsed = difference.tv_sec + in timeout_cb()
55 (int)newtime.tv_sec, elapsed); in timeout_cb()
/freebsd/sys/contrib/openzfs/cmd/zpool_influxdb/
H A Dzpool_influxdb.c151 int64_t elapsed; in print_scan_status() local
218 elapsed = (int64_t)time(NULL) - (int64_t)ps->pss_pass_start - in print_scan_status()
220 elapsed = (elapsed > 0) ? elapsed : 1; in print_scan_status()
222 rate = pass_exam / elapsed; in print_scan_status()
226 elapsed = in print_scan_status()
229 elapsed = (elapsed > 0) ? elapsed : 1; in print_scan_status()
231 rate = pass_exam / elapsed; in print_scan_status()
/freebsd/crypto/openssl/test/
H A Dtiming_load_creds.c113 struct rusage start, end, elapsed; in main() local
230 timersub(&end.ru_utime, &start.ru_stime, &elapsed.ru_stime); in main()
231 timersub(&end.ru_utime, &start.ru_utime, &elapsed.ru_utime); in main()
238 print_timeval("user ", &elapsed.ru_utime); in main()
239 print_timeval("sys ", &elapsed.ru_stime); in main()
/freebsd/contrib/netbsd-tests/lib/libc/sys/
H A Dt_clock_gettime.c117 long long elapsed; in check_timecounter() local
123 elapsed = 1000000000LL * (tsb.tv_sec - tsl.tv_sec) in check_timecounter()
127 (void)printf("%lld nsec\n", elapsed); in check_timecounter()
/freebsd/contrib/ntp/sntp/libevent/test/
H A Dregress_iocp.c94 DWORD elapsed; in count_wait_for() local
101 elapsed = GetTickCount(); in count_wait_for()
103 elapsed = GetTickCount() - elapsed; in count_wait_for()
104 ms -= elapsed; in count_wait_for()
/freebsd/contrib/libevent/test/
H A Dregress_iocp.c94 DWORD elapsed; in count_wait_for() local
101 elapsed = GetTickCount(); in count_wait_for()
103 elapsed = GetTickCount() - elapsed; in count_wait_for()
104 ms -= elapsed; in count_wait_for()
/freebsd/usr.sbin/bluetooth/bthidd/
H A Dbthidd.c54 static int32_t elapsed (int32_t tval);
168 if (elapsed(tval)) in main()
229 elapsed(int32_t tval) in elapsed() function
/freebsd/usr.bin/systat/
H A Difstat.c270 double elapsed = 0.0; in fetchifstat() local
321 elapsed = tv.tv_sec + (tv.tv_usec * 1e-6); in fetchifstat()
334 ifp->if_in_curtraffic /= elapsed; in fetchifstat()
335 ifp->if_out_curtraffic /= elapsed; in fetchifstat()
336 ifp->if_in_curpps /= elapsed; in fetchifstat()
337 ifp->if_out_curpps /= elapsed; in fetchifstat()
/freebsd/sys/contrib/device-tree/scripts/
H A Dgit-filter-branch354 elapsed=$(($now - $start_timestamp))
355 remaining=$(( ($commits - $count) * $elapsed / $count ))
356 if test $elapsed -gt 0
358 next_sample_at=$(( ($elapsed + 1) * $count / $elapsed ))
362 progress=" ($elapsed seconds passed, remaining $remaining predicted)"

12345