From owner-freebsd-arch Fri Nov 17 10:36:34 2000 Delivered-To: freebsd-arch@freebsd.org Received: from feral.com (feral.com [192.67.166.1]) by hub.freebsd.org (Postfix) with ESMTP id 56A3037B479 for ; Fri, 17 Nov 2000 10:36:31 -0800 (PST) Received: from zeppo.feral.com (IDENT:mjacob@zeppo [192.67.166.71]) by feral.com (8.9.3/8.9.3) with ESMTP id KAA15378; Fri, 17 Nov 2000 10:36:17 -0800 Date: Fri, 17 Nov 2000 10:36:15 -0800 (PST) From: Matthew Jacob Reply-To: mjacob@feral.com To: Mark Murray Cc: arch@FreeBSD.ORG Subject: RE: new monotime() call for all architectures. In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In case there's ever a sparc port, all of the worthwhile sparc machines have register onchip too. I like what you're doing with this- it would allow me to get rid of the nanotime calls I use to time some loops for the Qlogic driver. > > On 17-Nov-00 Mark Murray wrote: > > Hi all > > > > I need a fast-as-possible "time" inside the kernel to help > > speed up the /dev/random device. I say "time", because although > > it needs to be a function of time (preferably accurate and linear), > > it has no need whatsoever to be "real time", so a simple counter > > is quite OK. > > > > Pentiums, Alphas and IA64's all have a suitable register on chip, > > while I have to make do with nanotime(9) on i386 and i486. > > > > I have prepared a monotime(9) call for the i386, alpha and ia64 > > architectures (patch enclosed). I have been running this for a > > week or two now with promising results (on a Pentium). With > > the exception of the minimum of "glue" (and nanotime on older > > architectures), these functions reduce to one instruction. > > > > Comments? Suggestions? Nobel Prize nominations? I'd like to > > commit this soonish if possible. > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message