class StallAccumulator

Defined at line 29 of file ../../zircon/kernel/lib/stall/include/lib/stall.h

Maintains per-CPU stall timers in real time.

Its counters are conceptually continuous. In fact, we update the saved state whenever the

conditions change, so we can always compute the current value by extrapolating.

With respect to stall contributions, threads are always in one of these three states:

- Not contributing at all to any accumulator.

- Contributing to an accumulator as a progressing thread.

- Contributing to an accumulator as a stalling thread.

Public Methods

void Update (int op_contributors_progressing, int op_contributors_stalling)

Alter contributor counts by the given amount.

Only values between -1 and +1 are accepted.

Defined at line 33 of file ../../zircon/kernel/lib/stall/stall.cc

Stats Flush ()

Reads the current stats and resets them to zero.

Defined at line 38 of file ../../zircon/kernel/lib/stall/stall.cc

void ApplyContextSwitch (Thread * current_thread, Thread * next_thread)

Internally called by the scheduler at every context switch.

Defined at line 66 of file ../../zircon/kernel/lib/stall/stall.cc

Records