[Lazarus] How to program with time in milliseconds?

Michael Schnell mschnell at lumino.de
Mon May 12 13:32:33 CEST 2014


On 05/11/2014 09:44 AM, Graeme Geldenhuys wrote:
>
> Take a look at EpikTimer. It uses hardware timers where available, with
> an easy to use API for the developer.

IO took a look.

Seemingly this is only available for X86 and X86_64.

In Windows, "QueryPerformanceCounter" is called. I supposed (I don't 
have a Lazarus on Windows at hand) this library call in fact uses a 
hardware feature of the CPU instead of doing a time cosuming system call.

But on Linux the EpikTimer (exactly like "Now") just does 
"fpgettimeofday()" (exactly like "Now") and this finally does a system 
call.

Are there no better options ?

Thanks,
-Michael




More information about the Lazarus mailing list