On 10 August 2010 22:17, Martin Lucina <m...@kotelna.sk> wrote:

> > PS I recommend CLOCK_MONOTONIC, but it may not be available, and
> > requires -lrt ...
>
> Yeah, that's why gettimeofday() (and some equivalent I forget right now on
> Win32) is a decent portable alternative.
>
>
gettimeofday() is better for most users of RHEL as it can execute in user
space and transparently use rdtscp() and gain high resolution similar to
Windows' QueryPerformanceCounter().  The Linux & glibc developers are slow
to update all the timing APIs to use high resolution timers and the POSIX
clock API has suffered from changes between releases.

Visual Studio 2008 (although MSDN only says 2010) includes intrinsics for
rdtscp() but until 7 SP1/2008 R2 SP1 I get the impression that
QueryPerformanceCounter() only scales up to HPET.

Oodles and oodles of more blogs and papers appear about the topic as
multi-core gaming and general programming have been hitting such issues.
 VMware has been the most comprehensive so far.

https://www.vmware.com/pdf/vmware_timekeeping.pdf

-- 
Steve-o
_______________________________________________
zeromq-dev mailing list
zeromq-dev@lists.zeromq.org
http://lists.zeromq.org/mailman/listinfo/zeromq-dev

Reply via email to