From: Michal Sojka Date: Fri, 10 Dec 2010 14:59:30 +0000 (+0100) Subject: latester: Log command line and duration X-Git-Tag: fix-allnoconfig~233^2~7 X-Git-Url: http://rtime.felk.cvut.cz/gitweb/can-benchmark.git/commitdiff_plain/d8dc1797c94d0ec7eceac8715a035ddaa5c66dfc?hp=6feb4d52eea98f191e100a715234c8c0df621c5c latester: Log command line and duration --- diff --git a/latester/latester.c b/latester/latester.c index fb299aa..24015f1 100644 --- a/latester/latester.c +++ b/latester/latester.c @@ -81,6 +81,7 @@ struct { unsigned enobufs; unsigned overrun; unsigned lost; + struct timespec tic, tac; } stats; int num_interfaces = 0; @@ -582,6 +583,8 @@ void *measure_thread(void *arg) if (opt.oneattime) SEND(); + get_tstamp(&stats.tic); + while (!finish_flag && (opt.count == 0 || count < opt.count || msg_in_progress != 0)) { @@ -631,6 +634,8 @@ void *measure_thread(void *arg) } } + get_tstamp(&stats.tac); + for (i=0; i