PEP 418: Try to fill the "Action on suspend" column
This commit is contained in:
parent
4dc3e314eb
commit
a21dff29ba
30
pep-0418.txt
30
pep-0418.txt
|
@ -186,18 +186,18 @@ Summary
|
|||
Table summarizing all monotonic clocks:
|
||||
|
||||
|
||||
========================= =============== ================ =================
|
||||
========================= =============== ================ ====================
|
||||
Name Resolution Adjusted by NTP? Action on suspend
|
||||
========================= =============== ================ =================
|
||||
CLOCK_MONOTONIC_RAW 1 ns No ?
|
||||
gethrtime 1 ns No ?
|
||||
========================= =============== ================ ====================
|
||||
CLOCK_MONOTONIC_RAW 1 ns No Stopped
|
||||
gethrtime 1 ns No Not stopped
|
||||
mach_absolute_time() 1 ns No ?
|
||||
CLOCK_HIGHRES 1 ns No ?
|
||||
CLOCK_MONOTONIC 1 ns Yes on Linux Stopped on Linux
|
||||
QueryPerformanceCounter() 0.3 ns - 5 ns No ?
|
||||
GetTickCount[64]() 1 ms - 15 ms No ?
|
||||
QueryPerformanceCounter() 0.3 ns - 5 ns No Accuracy issue
|
||||
GetTickCount[64]() 1 ms - 15 ms No Include suspend time
|
||||
timeGetTime() 1 ms - 15 ms No ?
|
||||
========================= =============== ================ =================
|
||||
========================= =============== ================ ====================
|
||||
|
||||
mach_absolute_time
|
||||
^^^^^^^^^^^^^^^^^^
|
||||
|
@ -212,6 +212,10 @@ nanoseconds. According to the documentation (`Technical Q&A QA1398
|
|||
is always equals to one and does never fail, even if the function may fail
|
||||
according to its prototype.
|
||||
|
||||
mach_absolute_time() stops during a sleep on PowerPC CPU, but not on Intel CPU:
|
||||
`Different behaviour of mach_absolute_time() on i386 / ppc
|
||||
<http://lists.apple.com/archives/PerfOptimization-dev/2006/Jul/msg00024.html>`_.
|
||||
|
||||
mach_absolute_time() has a resolution of 1 nanosecond.
|
||||
|
||||
CLOCK_MONOTONIC, CLOCK_MONOTONIC_RAW
|
||||
|
@ -319,6 +323,9 @@ adjusted by SetSystemTimeAdjustment(). MSDN documentation:
|
|||
`GetTickCount() <http://msdn.microsoft.com/en-us/library/windows/desktop/ms724408(v=vs.85).aspx>`_,
|
||||
`GetTickCount64() <http://msdn.microsoft.com/en-us/library/windows/desktop/ms724411(v=vs.85).aspx>`_.
|
||||
|
||||
The elapsed time retrieved by GetTickCount or GetTickCount64 includes time the
|
||||
system spends in sleep or hibernation.
|
||||
|
||||
GetTickCount64() was added to Windows Vista and Windows Server 2008.
|
||||
|
||||
The clock resolution is 1 millisecond. Its accuracy is usually around 15 ms. It
|
||||
|
@ -371,6 +378,9 @@ resetting or drifting by way of adjtime() or settimeofday(). The hires timer
|
|||
is ideally suited to performance measurement tasks, where cheap, accurate
|
||||
interval timing is required.
|
||||
|
||||
The linearity of gethrtime() is not preserved accross cpr suspend-resume cycle
|
||||
(`Bug 4272663 <http://wesunsolve.net/bugid/id/4272663>`_).
|
||||
|
||||
Read the `gethrtime() manual page of Solaris 11
|
||||
<http://docs.oracle.com/cd/E23824_01/html/821-1465/gethrtime-3c.html#scrolltoc>`_.
|
||||
|
||||
|
@ -455,13 +465,15 @@ See also pthread_getcpuclockid().
|
|||
|
||||
|
||||
Windows: QueryUnbiasedInterruptTime
|
||||
-----------------------------------
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
Gets the current unbiased interrupt time from the biased interrupt time and the
|
||||
current sleep bias amount. This time is not affected by power management sleep
|
||||
transitions.
|
||||
|
||||
Is it monotonic?
|
||||
The elapsed time retrieved by the QueryUnbiasedInterruptTime function includes
|
||||
only time that the system spends in the working state.
|
||||
QueryUnbiasedInterruptTime() is not monotonic.
|
||||
|
||||
QueryUnbiasedInterruptTime() was introduced in Windows 7.
|
||||
|
||||
|
|
Loading…
Reference in New Issue