diff options
Diffstat (limited to 'tools/perf/util/parse-events.h')
-rw-r--r-- | tools/perf/util/parse-events.h | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/tools/perf/util/parse-events.h b/tools/perf/util/parse-events.h index 5cb002894a17..3fddd610d350 100644 --- a/tools/perf/util/parse-events.h +++ b/tools/perf/util/parse-events.h | |||
@@ -36,16 +36,17 @@ extern int parse_filter(const struct option *opt, const char *str, int unset); | |||
36 | #define EVENTS_HELP_MAX (128*1024) | 36 | #define EVENTS_HELP_MAX (128*1024) |
37 | 37 | ||
38 | enum { | 38 | enum { |
39 | PARSE_EVENTS__TERM_TYPE_NUM, | ||
40 | PARSE_EVENTS__TERM_TYPE_STR, | ||
41 | }; | ||
42 | |||
43 | enum { | ||
44 | PARSE_EVENTS__TERM_TYPE_USER, | ||
39 | PARSE_EVENTS__TERM_TYPE_CONFIG, | 45 | PARSE_EVENTS__TERM_TYPE_CONFIG, |
40 | PARSE_EVENTS__TERM_TYPE_CONFIG1, | 46 | PARSE_EVENTS__TERM_TYPE_CONFIG1, |
41 | PARSE_EVENTS__TERM_TYPE_CONFIG2, | 47 | PARSE_EVENTS__TERM_TYPE_CONFIG2, |
42 | PARSE_EVENTS__TERM_TYPE_SAMPLE_PERIOD, | 48 | PARSE_EVENTS__TERM_TYPE_SAMPLE_PERIOD, |
43 | PARSE_EVENTS__TERM_TYPE_BRANCH_SAMPLE_TYPE, | 49 | PARSE_EVENTS__TERM_TYPE_BRANCH_SAMPLE_TYPE, |
44 | PARSE_EVENTS__TERM_TYPE_NUM, | ||
45 | PARSE_EVENTS__TERM_TYPE_STR, | ||
46 | |||
47 | PARSE_EVENTS__TERM_TYPE_HARDCODED_MAX = | ||
48 | PARSE_EVENTS__TERM_TYPE_BRANCH_SAMPLE_TYPE, | ||
49 | }; | 50 | }; |
50 | 51 | ||
51 | struct parse_events__term { | 52 | struct parse_events__term { |
@@ -54,14 +55,16 @@ struct parse_events__term { | |||
54 | char *str; | 55 | char *str; |
55 | long num; | 56 | long num; |
56 | } val; | 57 | } val; |
57 | int type; | 58 | int type_val; |
58 | 59 | int type_term; | |
59 | struct list_head list; | 60 | struct list_head list; |
60 | }; | 61 | }; |
61 | 62 | ||
62 | int parse_events__is_hardcoded_term(struct parse_events__term *term); | 63 | int parse_events__is_hardcoded_term(struct parse_events__term *term); |
63 | int parse_events__new_term(struct parse_events__term **term, int type, | 64 | int parse_events__term_num(struct parse_events__term **_term, |
64 | char *config, char *str, long num); | 65 | int type_term, char *config, long num); |
66 | int parse_events__term_str(struct parse_events__term **_term, | ||
67 | int type_term, char *config, char *str); | ||
65 | void parse_events__free_terms(struct list_head *terms); | 68 | void parse_events__free_terms(struct list_head *terms); |
66 | int parse_events_modifier(struct list_head *list __used, char *str __used); | 69 | int parse_events_modifier(struct list_head *list __used, char *str __used); |
67 | int parse_events_add_tracepoint(struct list_head *list, int *idx, | 70 | int parse_events_add_tracepoint(struct list_head *list, int *idx, |