mirror of
https://gitee.com/bianbu-linux/tcm
synced 2025-04-18 19:34:45 -04:00
14 lines
No EOL
247 B
C
14 lines
No EOL
247 B
C
#include <stdio.h>
|
|
#include <string.h>
|
|
#include <unistd.h>
|
|
#include <stdlib.h>
|
|
#include <time.h>
|
|
#include <sys/time.h>
|
|
|
|
long long getus(void)
|
|
{
|
|
struct timeval tv;
|
|
|
|
gettimeofday(&tv, NULL);
|
|
return ((long long)tv.tv_sec * 1000000 + tv.tv_usec);
|
|
} |