26 #include <sys/timeb.h>
32 #define BILLION 1000000000L
35 #define MILLION 1000000L
41 #define HOUR (60 * MINUTE)
44 #define DAY (24 * HOUR)
47 #define USED_CLOCK CLOCK_MONOTONIC
50 typedef struct timespec
ptime;
ulong lap(ptime *ts, char *str)
Computes and prints the time lapse since ts.
void nanos(long ns, char *str)
Formats the time duration in nanoseconds ns into human readable string str.
void millis(long ms, char *str)
Formats the time duration in miliseconds ms into human readable string str.
void print_time_res(void)
Prints the timer resolution.
struct timespec ptime
Short type name for precise time.
Definition of basic types.
uint64_t ulong
ulong is uint64