git: vkernel - Avoid unnecessarily short sleeps, when not using precise timers.

Imre Vadasz ivadasz at crater.dragonflybsd.org
Sat Aug 26 03:48:31 PDT 2017


commit 2942cd4efadf27f772c73fed1345f710ab92ac66
Author: Imre Vadász <imre at vdsz.com>
Date:   Thu Aug 24 22:50:11 2017 +0200

    vkernel - Avoid unnecessarily short sleeps, when not using precise timers.
    
    * When use_precise_timer is disabled, it doesn't make sense to sleep for
      a short time in the systimer thread, since our time measurements wouldn't
      have the necessary precision to make use of this in the first place.
    
    * Since the CLOCK_MONOTONIC_FAST timer has a precision corresponding to the
      tick period of the host, use 1/10 of this value as the minimum sleep
      duration.

Summary of changes:
 sys/platform/vkernel64/platform/systimer.c | 28 +++++++++++++++++++++++++++-
 1 file changed, 27 insertions(+), 1 deletion(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/2942cd4efadf27f772c73fed1345f710ab92ac66


-- 
DragonFly BSD source repository



More information about the Commits mailing list