Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 Jul 2002 17:44:50 -0400
From:      kkonaka@mac.com
To:        freebsd-hackers@FreeBSD.ORG
Subject:   Re: Counting the clock cycles
Message-ID:  <sqbwuru58rx.wl@nue.mac.com>
In-Reply-To: <007801c22dd5$56d2ba50$0300a8c0@fivehundred>
References:  <Pine.BSF.4.21.0207171350290.79270-100000@InterJet.elischer.org> <007801c22dd5$56d2ba50$0300a8c0@fivehundred> <00d501c22dc4$57d08b00$0200a8c0@twothousand>

next in thread | previous in thread | raw e-mail | index | archive | help
> I need a way to properly determine passage of time
> that is not affected if I change the system clock
> for example.

how about using setitimer(2) - ITIMER_REAL?  

since it appears(?) on almost all unix(-like)
platforms this expires based only on callout (or
jiffies) ticks countdown, and settimeofday(2) never
seems to bother adjusting callout queues.

kenji

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?sqbwuru58rx.wl>