-
Notifications
You must be signed in to change notification settings - Fork 70
Open
Description
static inline uint64_t getVirtualCallTime()
{
struct timeval now;
gettimeofday(&now, NULL);
uint64_t time = (now.tv_sec % 1000) * 1000000 + now.tv_usec;
return time;
}
这里的时间记录(now.tv_sec % 1000)有问题,如果999s增加到了1000s,则会出现由999s变为0s的情况。
戴铭的代码中后续对这里可能出现的情况做了处理(SMCallTraceCore.c 308行):
if (time < pRecord->time) {
time += 100 * 1000000;
}
但你的代码遗漏了这里。
Metadata
Metadata
Assignees
Labels
No labels