MCPcopy Create free account
hub / github.com/async-profiler/async-profiler / resetCounters

Method resetCounters

src/callTraceStorage.cpp:309–323  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

307}
308
309void CallTraceStorage::resetCounters() {
310 for (LongHashTable* table = _current_table; table != NULL; table = table->prev()) {
311 u64* keys = table->keys();
312 CallTraceSample* values = table->values();
313 u32 capacity = table->capacity();
314
315 for (u32 slot = 0; slot < capacity; slot++) {
316 if (keys[slot] != 0) {
317 CallTraceSample& s = values[slot];
318 storeRelease(s.samples, 0);
319 storeRelease(s.counter, 0);
320 }
321 }
322 }
323}

Callers 1

tryResetCountersMethod · 0.80

Calls 5

storeReleaseFunction · 0.85
prevMethod · 0.80
valuesMethod · 0.80
keysMethod · 0.45
capacityMethod · 0.45

Tested by

no test coverage detected