From owner-freebsd-questions Tue May 15 7:54: 5 2001 Delivered-To: freebsd-questions@freebsd.org Received: from bdr-xcon.matchlogic.com (mail.matchlogic.com [205.216.147.127]) by hub.freebsd.org (Postfix) with ESMTP id 23CDF37B42C; Tue, 15 May 2001 07:54:01 -0700 (PDT) (envelope-from crandall@matchlogic.com) Received: by mail.matchlogic.com with Internet Mail Service (5.5.2653.19) id ; Tue, 15 May 2001 08:53:56 -0600 Message-ID: <5FE9B713CCCDD311A03400508B8B30130828ED85@bdr-xcln.corp.matchlogic.com> From: Charles Randall To: 'Poul-Henning Kamp' , Dave Leimbach Cc: tlambert2@mindspring.com, eischen@vigrid.com, dillon@earth.backplane.com, dleimbac@earthlink.net, freebsd-questions@FreeBSD.ORG, arch@FreeBSD.ORG Subject: RE: Gettimeofday Again... Date: Tue, 15 May 2001 08:53:38 -0600 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="iso-8859-1" Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Isn't that what kern.timecounter.method (documented in the microtime() man page) is for? That manual page states that this can be toggled. Charles -----Original Message----- From: Poul-Henning Kamp [mailto:phk@critter.freebsd.dk] Sent: Tuesday, May 15, 2001 8:11 AM To: Dave Leimbach Cc: tlambert2@mindspring.com; eischen@vigrid.com; dillon@earth.backplane.com; dleimbac@earthlink.net; freebsd-questions@FreeBSD.ORG; arch@FreeBSD.ORG Subject: Re: Gettimeofday Again... In message <200105151353.IAA27481@MPI-Softtech.Com>, Dave Leimbach writes: >Thanks for all of the great answers... > >For now if I want to see better performance of the timing code I can just >"sysctl -w kern.timecounter.hardware=TSC"?? You can try it, but depending on a lot of stuff it may not A) work nor B) be a good idea if it does. If you want a faster (but less exact!) gettimeofday, change the call to microtime() to getmicrotime() in the gettimeofday() in kern_time.c -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message