MCPcopy Create free account
hub / github.com/FEX-Emu/FEX / GetTime

Function GetTime

FEXCore/Source/Utils/Profiler.cpp:21–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19#include <time.h>
20#ifndef _WIN32
21static inline uint64_t GetTime() {
22 // We want the time in the least amount of overhead possible
23 // clock_gettime will do a VDSO call with the least amount of overhead
24 struct timespec ts;
25 clock_gettime(CLOCK_MONOTONIC, &ts);
26 return ts.tv_sec * 1'000'000'000ULL + ts.tv_nsec;
27}
28#else
29
30static inline uint64_t GetTime() {

Callers 2

ProfilerBlockMethod · 0.85
~ProfilerBlockMethod · 0.85

Calls 1

clock_gettimeFunction · 0.85

Tested by

no test coverage detected