|
libfossil
|
State for the fsl_timer_xxx() family of functions. More...
#include "util.h"
Data Fields | |
| uint64_t | system |
| The amount of time (microseconds) spent in "kernel space". | |
| uint64_t | user |
| The amount of time (microseconds) spent in "user space". | |
| uint64_t | wall |
| The microseconds of "wall clock" time. | |
State for the fsl_timer_xxx() family of functions.
Achtung: timer support is only enabled if the library is built with the proper clock support. Windows builds mostly support it automatically (all except wall clock time) and non-Windows builds do if the library is built with HAVE_CLOCK_GETTIME (for clock_gettime(2)) and HAVE_GETRUSAGE (for getrusage(2)) both set to true values. That said: the library currently assumes that non-Windows builds have both of those POSIX-2008 functions. On Windows, building with HAVE_CLOCK_GETTIME is necessary only for fsl_timer::wall.
Example usage:
After that, tTotal contains the microseconds of time which elapsed between the time tRun was started and the time fsl_timer_add() was called.
| uint64_t fsl_timer::system |
| uint64_t fsl_timer::user |
| uint64_t fsl_timer::wall |