Note: limited to a max time diff of 2147 * 10^6 useconds! */
| 1384 | |
| 1385 | /* Note: limited to a max time diff of 2147 * 10^6 useconds! */ |
| 1386 | static inline int get_time_diff(struct timeval *begin) |
| 1387 | { |
| 1388 | struct timeval end; |
| 1389 | |
| 1390 | gettimeofday(&end, NULL); |
| 1391 | |
| 1392 | /* difference is returned in microseconds */ |
| 1393 | return (long long)(end.tv_sec*1000000 + end.tv_usec) |
| 1394 | - (long long)(begin->tv_sec*1000000 + begin->tv_usec); |
| 1395 | } |
| 1396 | |
| 1397 | static inline unsigned long long get_clock_diff(struct timespec *begin) |
| 1398 | { |
no outgoing calls
no test coverage detected