This struct provides a namespace for platform‐neutral system‐clock procedures.
Synopsis
Declared in <bsls_timeutil.h>
struct TimeUtil;
Description
This struct provides a namespace for a set of platform‐neutral pure procedures to access real‐time system clock functionality. High‐resolution time functions intended for interval‐timing return an interval in nanoseconds (1 nsec = 1E‐9 sec) as a platform‐independent 64‐bit integer.
For maximum performance on some platforms where fetching the native clock is significantly faster than converting the fetched value to nanoseconds, this class also provides a "raw" method returning an opaque native time value and a conversion method returning a value in nanoseconds.
Type Aliases
Name |
Static Member Functions
Name |
Description |
Convert an opaque native time value to nanoseconds. |
|
Return the current process system CPU time in nanoseconds. |
|
Load the current process system and user CPU times in nanoseconds. |
|
Return the current process user CPU time in nanoseconds. |
|
Return the current thread system CPU time in nanoseconds. |
|
Load the current thread system and user CPU times in nanoseconds. |
|
Return the current thread user CPU time in nanoseconds. |
|
Return the current wall time in nanoseconds from a fixed origin. |
|
Load the current time as an opaque platform‐dependent value. |
|
Perform platform‐dependent initialization for these utilities. |
Created with MrDocs