#include <time.h>
#include <sys/time.h>
Go to the source code of this file.
◆ simpletimer_start()
struct timeval simpletimer_start |
( |
void |
| ) |
|
|
inline |
◆ simpletimer_stop()
double simpletimer_stop |
( |
const struct timeval & |
start_time | ) |
|
|
inline |
Definition at line 29 of file DataQuality/HanConfigGenerator/src/simpletimer.h.
31 struct timeval stop_time;
32 struct timeval diff_time;
33 gettimeofday(&stop_time, NULL);
34 diff_time.tv_sec = stop_time.tv_sec - start_time.tv_sec;
35 diff_time.tv_usec = stop_time.tv_usec - start_time.tv_usec;
36 return (diff_time.tv_sec*1000.0) + (diff_time.tv_usec/1000.0);