summaryrefslogtreecommitdiff
path: root/tools/perf/util/stat.h
diff options
context:
space:
mode:
authorJiri Olsa <jolsa@redhat.com>2015-08-07 10:51:03 (GMT)
committerArnaldo Carvalho de Melo <acme@redhat.com>2015-08-08 17:16:49 (GMT)
commitd809560b36a7ed31fbaf3719fdf79ddcbd30950b (patch)
treec9ec855af138848caccbe3a0a8c43c54e26a9999 /tools/perf/util/stat.h
parentf1d800bf615b84ca253af372d2dac8cdef743a20 (diff)
downloadlinux-d809560b36a7ed31fbaf3719fdf79ddcbd30950b.tar.xz
perf stat: Move perf_counts struct and functions into separate object
Moving 'struct perf_counts' and associated functions into separate object, so we could remove stat.c object dependency from python build. It makes the python code to build properly, because it fails to load due to missing stat-shadow.c object dependency if some patches from Kan Liang are applied. So apply this one, then Kan's. Signed-off-by: Jiri Olsa <jolsa@kernel.org> Cc: Andi Kleen <ak@linux.intel.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Kan Liang <kan.liang@intel.com> Cc: Namhyung Kim <namhyung@kernel.org> Link: http://lkml.kernel.org/r/20150807105103.GB8624@krava.brq.redhat.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/stat.h')
-rw-r--r--tools/perf/util/stat.h30
1 files changed, 0 insertions, 30 deletions
diff --git a/tools/perf/util/stat.h b/tools/perf/util/stat.h
index 0b897b0..62448c8 100644
--- a/tools/perf/util/stat.h
+++ b/tools/perf/util/stat.h
@@ -33,23 +33,6 @@ enum aggr_mode {
AGGR_THREAD,
};
-struct perf_counts_values {
- union {
- struct {
- u64 val;
- u64 ena;
- u64 run;
- };
- u64 values[3];
- };
-};
-
-struct perf_counts {
- s8 scaled;
- struct perf_counts_values aggr;
- struct xyarray *values;
-};
-
struct perf_stat_config {
enum aggr_mode aggr_mode;
bool scale;
@@ -57,12 +40,6 @@ struct perf_stat_config {
unsigned int interval;
};
-static inline struct perf_counts_values*
-perf_counts(struct perf_counts *counts, int cpu, int thread)
-{
- return xyarray__entry(counts->values, cpu, thread);
-}
-
void update_stats(struct stats *stats, u64 val);
double avg_stats(struct stats *stats);
double stddev_stats(struct stats *stats);
@@ -96,13 +73,6 @@ void perf_stat__update_shadow_stats(struct perf_evsel *counter, u64 *count,
void perf_stat__print_shadow_stats(FILE *out, struct perf_evsel *evsel,
double avg, int cpu, enum aggr_mode aggr);
-struct perf_counts *perf_counts__new(int ncpus, int nthreads);
-void perf_counts__delete(struct perf_counts *counts);
-
-void perf_evsel__reset_counts(struct perf_evsel *evsel);
-int perf_evsel__alloc_counts(struct perf_evsel *evsel, int ncpus, int nthreads);
-void perf_evsel__free_counts(struct perf_evsel *evsel);
-
void perf_evsel__reset_stat_priv(struct perf_evsel *evsel);
int perf_evsel__alloc_stat_priv(struct perf_evsel *evsel);
void perf_evsel__free_stat_priv(struct perf_evsel *evsel);