Discussion:
How to get tick count on linux
Suneel Kandru
2005-03-07 06:38:13 UTC
Permalink
what is the windows GetTickCount() equal function linux

Thank you
Shrinand Javadekar
2005-03-07 06:59:55 UTC
Permalink
On Sun, 6 Mar 2005 22:38:13 -0800, Suneel Kandru
Post by Suneel Kandru
what is the windows GetTickCount() equal function linux
Thank you
As far as I know, the API to be used in gettimeofday();

Google says:
"On Linux we use the gettimeofday() API. It is the only API that times
at the sub-millisecond level."

Thanks
-Shri

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive: http://mail.nl.linux.org/kernelnewbies/
FAQ: http://kernelnewbies.org/faq/
Srinivas G.
2005-03-09 14:14:19 UTC
Permalink
Dear Suneel,



In linux jiffies gives the clock ticks. This value is depends on the HZ
value defined in the linux/sched.h file.



The do_gettimeofday() will gives the values in structure variable of
type timeval structure which contains the two variables called seconds
and micro seconds. Structure timeval is included in the linux/time.h
file.



Regards,

Srinivas G



-----Original Message-----
From: kernelnewbies-***@nl.linux.org
[mailto:kernelnewbies-***@nl.linux.org] On Behalf Of Suneel Kandru
Sent: Monday, March 07, 2005 12:08 PM
To: ***@nl.linux.org
Subject: How to get tick count on linux



what is the windows GetTickCount() equal function linux



Thank you

Loading...