Round displayed pps (instead of truncating)

This commit is contained in:
Ed Maste 2012-08-08 13:54:26 +00:00
parent fdc8ba5e71
commit ef63ce395a
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=239139

View File

@ -1076,7 +1076,7 @@ main(int arc, char **argv)
pps = toc.tv_sec* 1000000 + toc.tv_usec;
if (pps < 10000)
continue;
pps = (my_count - prev)*1000000 / pps;
pps = ((my_count - prev) * 1000000 + pps / 2) / pps;
D("%" PRIu64 " pps", pps);
prev = my_count;
toc = now;