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

Function mem_phase_committed

src/foundation/mem.c:693–705  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

691static atomic_int g_mem_phase_enabled = ATOMIC_VAR_INIT(-1); /* -1 = undecided */
692
693static size_t mem_phase_committed(void) {
694 size_t elapsed_ms = 0;
695 size_t user_ms = 0;
696 size_t sys_ms = 0;
697 size_t rss = 0;
698 size_t peak_rss = 0;
699 size_t commit = 0;
700 size_t peak_commit = 0;
701 size_t faults = 0;
702 mi_process_info(&elapsed_ms, &user_ms, &sys_ms, &rss, &peak_rss, &commit, &peak_commit,
703 &faults);
704 return commit;
705}
706
707static bool mem_phase_enabled(void) {
708 int state = atomic_load_explicit(&g_mem_phase_enabled, memory_order_acquire);

Callers 2

cbm_mem_phase_markFunction · 0.85
cbm_mem_phase_resetFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected