Browse Source

Add cgminer compatibility macro for ms_tdiff

Luke Dashjr 12 years ago
parent
commit
365cd66cde
1 changed files with 2 additions and 0 deletions
  1. 2 0
      util.h

+ 2 - 0
util.h

@@ -362,6 +362,8 @@ long timer_elapsed_us(const struct timeval *tvp_timer, const struct timeval *tvp
 	return timeval_to_us(&tv);
 }
 
+#define ms_tdiff(end, start)  (timer_elapsed_us(start, end) / 1000)
+
 static inline
 int timer_elapsed(const struct timeval *tvp_timer, const struct timeval *tvp_now)
 {