Lines Matching defs:counter
75 * copy the current counter values into a local array. This buffer
195 incrementcounter(isc_stats_t *stats, int counter) {
201 * counter while we "writing" a counter field. The write access itself
208 prev = isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].lo, 1);
218 isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].hi, 1);
221 isc_atomic_xaddq((isc_int64_t *)&stats->counters[counter], 1);
224 stats->counters[counter]++;
233 decrementcounter(isc_stats_t *stats, int counter) {
241 prev = isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].lo, -1);
243 isc_atomic_xadd((isc_int32_t *)&stats->counters[counter].hi,
247 isc_atomic_xaddq((isc_int64_t *)&stats->counters[counter], -1);
250 stats->counters[counter]--;
295 isc_stats_increment(isc_stats_t *stats, isc_statscounter_t counter) {
297 REQUIRE(counter < stats->ncounters);
299 incrementcounter(stats, (int)counter);
303 isc_stats_decrement(isc_stats_t *stats, isc_statscounter_t counter) {
305 REQUIRE(counter < stats->ncounters);
307 decrementcounter(stats, (int)counter);