MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / cbm_timebase_initialize

Function cbm_timebase_initialize

src/foundation/platform.c:263–269  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

261static pthread_once_t timebase_once = PTHREAD_ONCE_INIT;
262
263static void cbm_timebase_initialize(void) {
264 (void)mach_timebase_info(&timebase_info);
265 if (timebase_info.numer == 0 || timebase_info.denom == 0) {
266 timebase_info.numer = 1;
267 timebase_info.denom = 1;
268 }
269}
270
271uint64_t cbm_now_ns(void) {
272 (void)pthread_once(&timebase_once, cbm_timebase_initialize);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected