[svn] Better selection of POSIX clocks.

This commit is contained in:
hniksic
2005-04-08 11:19:20 -07:00
parent ab05800310
commit 14a2d25b2e
4 changed files with 268 additions and 199 deletions

View File

@@ -534,10 +534,10 @@ calc_rate (wgint bytes, double msecs, int *units)
if (msecs == 0)
/* If elapsed time is exactly zero, it means we're under the
granularity of the timer. This can easily happen on systems
resolution of the timer. This can easily happen on systems
that use time() for the timer. Since the interval lies between
0 and the timer's granularity, assume half the granularity. */
msecs = ptimer_granularity () / 2.0;
0 and the timer's resolution, assume half the resolution. */
msecs = ptimer_resolution () / 2.0;
dlrate = 1000.0 * bytes / msecs;
if (dlrate < 1024.0)