From owner-freebsd-hackers Wed Jul 17 12: 1:45 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A5C5637B400 for ; Wed, 17 Jul 2002 12:01:42 -0700 (PDT) Received: from mail.empirequest.com (www.empirequest.com [216.126.10.210]) by mx1.FreeBSD.org (Postfix) with ESMTP id 91EA943E58 for ; Wed, 17 Jul 2002 12:01:41 -0700 (PDT) (envelope-from spinlock_lists@empirequest.com) Received: (qmail 4435 invoked by uid 89); 17 Jul 2002 19:01:23 -0000 Received: from unknown (HELO twothousand) (spinlock?lists@empirequest.com@192.168.0.2) by www.empirequest.com with SMTP; 17 Jul 2002 19:01:23 -0000 Message-ID: <00d501c22dc4$57d08b00$0200a8c0@twothousand> From: "Andrei Cojocaru" To: Subject: Counting the clock cycles Date: Wed, 17 Jul 2002 13:01:22 -0600 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2600.0000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I was asking around in #freebsdhelp on EFNet what the equivalent of GetTickCount() in the Win32 API is in FreeBSD. I need a way to properly determine passage of time that is not affected if I change the system clock for example. The only way I'm aware that you can do that is by counting the number of clock cycles since system startup. What function does that in FreeBSD? I'd also like a Linux way if possible. (that is a way that will work across all UNIX clones). Thanks and please include my email in the reply directly since I'm not signed up to this mailing list. Thanks once again. ---- Andrei Cojocaru spinlock_lists@empirequest.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message