[fpc-devel] High performance Linux timer

Vladimir Zhirov vvzh.home at gmail.com
Mon May 19 12:42:00 CEST 2008


Graeme Geldenhuys wrote:
> Does anybody know if there is a Linux (or generic Unix) high
> performance timer API available. Something like the Win32 API
> QueryPerformanceCounter()?

Graeme, maybe this link will help:

There are some functions mentioned there in addition to RDTSC:
- gettimeofday
- clock_gettime
- ftime

> Anybody know what Win32's QueryPerformanceCounter() uses internally to
> get a stable timer?  Or is QueryPerformanceCounter also susceptible to
> powersaving features?

I found an article named "Beware of QueryPerformanceCounter()" on
that gives some information about this function.
It will not answer your questions directly, but may be useful.


More information about the fpc-devel mailing list