This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
OS X clock_gettime() and clock_getres() emulation
authorJarkko Hietaniemi <jhi@iki.fi>
Thu, 14 Jan 2016 13:06:26 +0000 (08:06 -0500)
committerJarkko Hietaniemi <jhi@iki.fi>
Sat, 13 Feb 2016 16:39:11 +0000 (11:39 -0500)
commit1e845d0cc6028e1285db33e93c9bd63d61b58340
treeb8c445105067e5aa9d7103a8ff345054071fffc0
parent0915f2cbe49dd78015d79ea3c20fca47d1ac1c49
OS X clock_gettime() and clock_getres() emulation

Note that CLOCK_REALTIME and CLOCK_MONOTONIC are the same clock,
so both are monotonic.

The difference is that the CLOCK_REALTIME is offset by the
gettimeofday() result on the first use of these interfaces,
and thereafter will closely track the gettimeofday() values.

https://developer.apple.com/library/mac/qa/qa1398/_index.html
"Mach Absolute Time Units"
dist/Time-HiRes/HiRes.xs
dist/Time-HiRes/Makefile.PL