aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJiri Olsa <[email protected]>2016-01-05 22:09:08 +0100
committerArnaldo Carvalho de Melo <[email protected]>2016-01-06 20:11:15 -0300
commit8058a30ce174060a3c8156dc87b4d4ae39e8281b (patch)
treeac51cf6ffa7c5b20f1d1628255a8522fb8254160
parent91a2c3d54fd4b5be4e25acc1d8c1cc9a28319774 (diff)
perf script: Add process_stat/process_stat_interval scripting interface
Python and perl scripting code will define those callbacks and get stat data. Signed-off-by: Jiri Olsa <[email protected]> Tested-by: Kan Liang <[email protected]> Cc: David Ahern <[email protected]> Cc: Namhyung Kim <[email protected]> Cc: Peter Zijlstra <[email protected]> Link: http://lkml.kernel.org/r/[email protected] [ Rename 'time' parameters to 'tstamp', to fix the build in older distros ] Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
-rw-r--r--tools/perf/util/trace-event.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/perf/util/trace-event.h b/tools/perf/util/trace-event.h
index b85ee55cca0c..bce5b1dac268 100644
--- a/tools/perf/util/trace-event.h
+++ b/tools/perf/util/trace-event.h
@@ -65,6 +65,7 @@ int tracing_data_put(struct tracing_data *tdata);
struct addr_location;
struct perf_session;
+struct perf_stat_config;
struct scripting_ops {
const char *name;
@@ -75,6 +76,9 @@ struct scripting_ops {
struct perf_sample *sample,
struct perf_evsel *evsel,
struct addr_location *al);
+ void (*process_stat)(struct perf_stat_config *config,
+ struct perf_evsel *evsel, u64 tstamp);
+ void (*process_stat_interval)(u64 tstamp);
int (*generate_script) (struct pevent *pevent, const char *outfile);
};