mgxapp/lib/tools.c
/*
	Return the current time as an integer in microseconds (mu-sec) past the
	epoch.
*/
Return the current time as an integer in microseconds (mu-sec) past the
epoch.
Return the current time as an integer in microseconds ( mu - sec ) past the epoch .
extern long long mt_now( void ) {
	struct timespec ts;
	long long		now = 0;
	clock_gettime( CLOCK_REALTIME, &ts );
	now = (ts.tv_sec * 1000000) + (ts.tv_nsec/1000);
	return now;
}
extern long long mt_now ( void ) { struct timespec ts ; long long now = 0 ; clock_gettime ( CLOCK_REALTIME , & ts ) ; now = ( ts . tv_sec * 1000000 ) + ( ts . tv_nsec / 1000 ) ; return now ; }
Return the current time as an integer in microseconds (mu-sec) past the
epoch.
Return the current time as an integer in microseconds ( mu - sec ) past the epoch .