From owner-freebsd-arch Mon Apr 15 10:46:44 2002 Delivered-To: freebsd-arch@freebsd.org Received: from herbelot.dyndns.org (d013.dhcp212-198-27.noos.fr [212.198.27.13]) by hub.freebsd.org (Postfix) with ESMTP id B739437B405; Mon, 15 Apr 2002 10:46:34 -0700 (PDT) Received: from herbelot.com (tulipe.herbelot.nom [192.168.1.5]) by herbelot.dyndns.org (8.9.3/8.9.3) with ESMTP id TAA19437; Mon, 15 Apr 2002 19:46:32 +0200 (CEST) (envelope-from thierry@herbelot.com) Message-ID: <3CBB11F8.451D28AB@herbelot.com> Date: Mon, 15 Apr 2002 19:46:32 +0200 From: Thierry Herbelot X-Mailer: Mozilla 4.79 [en] (X11; U; Linux 2.4.2 i386) X-Accept-Language: en MIME-Version: 1.0 To: Poul-Henning Kamp Cc: arch@FreeBSD.ORG Subject: Re: get{bin,micro,nano}[up]time() - what precision ? References: <54342.1018890897@critter.freebsd.dk> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Poul-Henning Kamp wrote: > > I'm soliciting input from users of the get*time() family of functions > in the kernel on what the minimal desirable precision is. > > Currently they return a timestamp which is no more than 1/HZ out > of date. For contemporary values of HZ, that seems to be adequate. > > As people increase HZ to above 10000, it starts to cost more to > update timecounters every tick, and the question naturally arises: > what is the target resolution for get*time() functions ? > > Would anybody get in trouble if the precision never got better > than 10msec, even for higher HZ ? > > If so, would 1msec be an acceptable limit ? Hello, I am investigating a "centralized clock" appliance, where a number of FreeBSD PCs would spit out a more or less precise date on the Ethernet. The goal would be : all FreeBSD PCs will run NTP, with a local GPS clock, and will peer with the other PCs in order to be hardened against the loss of a GPS box. The FreeBSD PCs only run some kind of endless loop, copying the local, "precise relative to UTC" time on Ethernet packets, sent approximatively once every msec. Thus, I would like to be able to read the local time at 2000Hz to (max) 5000Hz, with the correlative precision. Thus, 1msec seems to be a little short on precision. Cheers TfH > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message