#include "ScopeFunction.h"
#include <time.h>
#include <sys/time.h>
Go to the source code of this file.
◆ CURRTIME
Value:
Definition at line 45 of file Macro.h.
◆ GTMONOTIMENS
| #define GTMONOTIMENS |
( |
|
ret | ) |
|
Value: { \
struct timespec ts; \
clock_gettime(CLOCK_MONOTONIC, &ts); \
ret=(ts.tv_sec); \
ret=ret * 1000000000; \
ret+=ts.tv_nsec;\
}
Definition at line 66 of file Macro.h.
◆ GTTIME
Value: { \
struct timeval tv; \
gettimeofday(&tv, NULL); \
ret = (tv.tv_sec); \
ret = ret * 1000000; \
ret+=tv.tv_usec;\
}
Definition at line 21 of file Macro.h.
◆ LOG_CURRTIME
Value: {\
CURRTIME(t);\
printf("%s : %lld\n",__func__,t);\
}
Definition at line 49 of file Macro.h.
◆ MONOCURRTIME
| #define MONOCURRTIME |
( |
|
ret | ) |
|
Value:int64_t ret; \
{ \
MONOTIMEUS(ret); \
}
Definition at line 81 of file Macro.h.
◆ MONOTIMEUS
| #define MONOTIMEUS |
( |
|
ret | ) |
|
Value:{ \
GTMONOTIMENS(ret); \
ret = ret / 1000; \
}
Definition at line 75 of file Macro.h.
◆ PRINTFLOW
◆ PROCESSTIME
| #define PROCESSTIME |
( |
|
var, |
|
|
|
x |
|
) |
| |
Value: int64_t var;\
{ int64_t st,et;\
GTTIME(st);\
x;\
GTTIME(et);\
var=et-st;\
}
Definition at line 57 of file Macro.h.
◆ TIMEOP
Value: { \
int64_t st,et; \
GTTIME(st); \
{x;} \
GTTIME(et); \
printf("%s -> %lld\n",n,et-st); \
}
Definition at line 29 of file Macro.h.
◆ TIMEOP_LOG
| #define TIMEOP_LOG |
( |
|
n, |
|
|
|
x, |
|
|
|
d |
|
) |
| |
Value: { \
int64_t st,et; \
GTTIME(st); \
{x;} \
GTTIME(et); \
if(d) printf("%s -> %ld\n",n,et-st); \
}
Definition at line 37 of file Macro.h.
◆ XPROCESSTIME
| #define XPROCESSTIME |
( |
|
var, |
|
|
|
x |
|
) |
| |
Value:
Definition at line 54 of file Macro.h.