From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932331AbbGUMdd (ORCPT ); Tue, 21 Jul 2015 08:33:33 -0400 Received: from mx1.redhat.com ([209.132.183.28]:34920 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932201AbbGUMd3 (ORCPT ); Tue, 21 Jul 2015 08:33:29 -0400 From: Jiri Olsa To: Arnaldo Carvalho de Melo Cc: lkml , David Ahern , Ingo Molnar , Namhyung Kim , Peter Zijlstra Subject: [PATCH 43/47] perf script: Add process_stat/process_stat_interval scripting interface Date: Tue, 21 Jul 2015 14:32:03 +0200 Message-Id: <1437481927-29538-44-git-send-email-jolsa@kernel.org> In-Reply-To: <1437481927-29538-1-git-send-email-jolsa@kernel.org> References: <1437481927-29538-1-git-send-email-jolsa@kernel.org> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Python and perl scripting code will define those callbacks and get stat data. Link: http://lkml.kernel.org/n/tip-6802z3siu5f59wdsmhaym3wm@git.kernel.org Signed-off-by: Jiri Olsa --- tools/perf/util/trace-event.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/perf/util/trace-event.h b/tools/perf/util/trace-event.h index d5168f0be4ec..d84147deae58 100644 --- a/tools/perf/util/trace-event.h +++ b/tools/perf/util/trace-event.h @@ -63,6 +63,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; @@ -73,6 +74,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 time); + void (*process_stat_interval) (u64 time); int (*generate_script) (struct pevent *pevent, const char *outfile); }; -- 2.4.3