clock - determine processor time
#include <time.h>
clock_t clock(void);
The clock() function returns an approximation of processor time used by the program.
The value returned is the CPU time used so far as a clock_t
;
to get the number of seconds used, divide by
CLOCKS_PER_SEC. If the processor time used is not
available or its value cannot be represented, the function returns the
value (clock_t) -1
.
clock_gettime(2), getrusage(2), times(2)