From 5242519b0296d128425368fc6ab17f541d5fa775 Mon Sep 17 00:00:00 2001 From: Ingo Molnar Date: Tue, 26 May 2009 09:17:18 +0200 Subject: perf stat: Convert to Git option parsing Remove getopt usage and use Git's much more advanced and more compact command option library. Extend the event parser library with the extensions that were in perf-stat before. Cc: Peter Zijlstra Cc: Mike Galbraith Cc: Paul Mackerras Cc: Corey Ashford Cc: Marcelo Tosatti Cc: Arnaldo Carvalho de Melo Cc: John Kacur LKML-Reference: Signed-off-by: Ingo Molnar --- Documentation/perf_counter/util/parse-events.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'Documentation/perf_counter/util/parse-events.h') diff --git a/Documentation/perf_counter/util/parse-events.h b/Documentation/perf_counter/util/parse-events.h index 6e2ebe5ff7d7..0da306bb9028 100644 --- a/Documentation/perf_counter/util/parse-events.h +++ b/Documentation/perf_counter/util/parse-events.h @@ -1,6 +1,16 @@ +/* + * Parse symbolic events/counts passed in as options: + */ + extern int nr_counters; extern __u64 event_id[MAX_COUNTERS]; +extern int event_mask[MAX_COUNTERS]; + +#define EVENT_MASK_KERNEL 1 +#define EVENT_MASK_USER 2 + +extern char *event_name(int ctr); extern int parse_events(const struct option *opt, const char *str, int unset); -- cgit v1.2.2