They were flushed once per application previously, causing workload with many
applications to trigger too many flush on stop, which in turn caused buffer
padding bloat.
* The pseudo-code for stop behavior on per-uid buffers was:
flush session's buffers
for each application:
- stop tracing
- wait quiescent
- flush buffers
- push metadata
Now doing, for per-uid buffers:
for each application:
- stop tracing
- wait quiescent
- push metadata
flush session's buffers
* And for per-pid buffers:
Previously:
for each application:
- stop tracing
- wait quiescent
- flush buffers
- push metadata
Now:
for each application:
- stop tracing
- wait quiescent
- push metadata
for each application:
- flush buffers
Fixes #497
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>