From owner-freebsd-hackers Wed Jun 18 03:41:56 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id DAA10294 for hackers-outgoing; Wed, 18 Jun 1997 03:41:56 -0700 (PDT) Received: from genesis.atrad.adelaide.edu.au (genesis.atrad.adelaide.edu.au [129.127.96.120]) by hub.freebsd.org (8.8.5/8.8.5) with ESMTP id DAA10286 for ; Wed, 18 Jun 1997 03:41:45 -0700 (PDT) Received: (from msmith@localhost) by genesis.atrad.adelaide.edu.au (8.8.5/8.7.3) id UAA22004; Wed, 18 Jun 1997 20:08:42 +0930 (CST) From: Michael Smith Message-Id: <199706181038.UAA22004@genesis.atrad.adelaide.edu.au> Subject: Re: High Resolution Timers, How? In-Reply-To: <199706180959.LAA19607@labinfo.iet.unipi.it> from Luigi Rizzo at "Jun 18, 97 11:59:14 am" To: luigi@labinfo.iet.unipi.it (Luigi Rizzo) Date: Wed, 18 Jun 1997 20:08:42 +0930 (CST) Cc: msmith@atrad.adelaide.edu.au, Shimon@i-Connect.Net, FreeBSD-Hackers@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL28 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk Luigi Rizzo stands accused of saying: > > Simon Shapiro stands accused of saying: > > > > > > I am in need for a precise, high resolution timer within the kernel. > > > I need it to time certain instructions, functions, and I/O events. > > > > microtime() > > It is worth mentioning that the Pentium also has an accessible cycle > counter, which can be read using the rdtsc asm instruction (or the > equivalent rdtsc() function in the kernel). microtime() uses it. Ask Bruce if you need to know more 8) -- ]] Mike Smith, Software Engineer msmith@gsoft.com.au [[ ]] Genesis Software genesis@gsoft.com.au [[ ]] High-speed data acquisition and (GSM mobile) 0411-222-496 [[ ]] realtime instrument control. (ph) +61-8-8267-3493 [[ ]] Unix hardware collector. "Where are your PEZ?" The Tick [[