perf tools: Fix one of the probe events to exclude kernel
[deliverable/linux.git] / tools / perf / util / stat.h
CommitLineData
0007ecea
XG
1#ifndef __PERF_STATS_H
2#define __PERF_STATS_H
3
d944c4ee 4#include <linux/types.h>
0007ecea
XG
5
6struct stats
7{
8 double n, mean, M2;
ffe4f3c0 9 u64 max, min;
0007ecea
XG
10};
11
12void update_stats(struct stats *stats, u64 val);
13double avg_stats(struct stats *stats);
14double stddev_stats(struct stats *stats);
15double rel_stddev_stats(double stddev, double avg);
16
ffe4f3c0
DA
17static inline void init_stats(struct stats *stats)
18{
19 stats->n = 0.0;
20 stats->mean = 0.0;
21 stats->M2 = 0.0;
22 stats->min = (u64) -1;
23 stats->max = 0;
24}
0007ecea 25#endif
This page took 0.101567 seconds and 5 git commands to generate.