• Home
  • Raw
  • Download

Lines Matching refs:str

188 				char *str, char *help)  in parse_events__handle_error()  argument
190 if (WARN(!str, "WARNING: failed to provide error string\n")) { in parse_events__handle_error()
197 err->str = str; in parse_events__handle_error()
203 err->first_str = err->str; in parse_events__handle_error()
204 err->str = str; in parse_events__handle_error()
210 err->str, err->help); in parse_events__handle_error()
211 free(err->str); in parse_events__handle_error()
212 err->str = str; in parse_events__handle_error()
287 char *str = strchr(name, ':'); in tracepoint_name_to_path() local
289 if (path == NULL || str == NULL) { in tracepoint_name_to_path()
294 path->system = strndup(name, str - name); in tracepoint_name_to_path()
295 path->name = strdup(str+1); in tracepoint_name_to_path()
342 return term->val.str; in get_config_name()
426 static int parse_aliases(char *str, const char *names[][EVSEL__MAX_ALIASES], int size) in parse_aliases() argument
434 if (n > longest && !strncasecmp(str, names[i][j], n)) in parse_aliases()
479 char *str = op_result[i]; in parse_events_add_cache() local
481 n += snprintf(name + n, MAX_NAME_LEN - n, "-%s", str); in parse_events_add_cache()
484 cache_op = parse_aliases(str, evsel__hw_cache_op, in parse_events_add_cache()
494 cache_result = parse_aliases(str, evsel__hw_cache_result, in parse_events_add_cache()
531 const char *str; in tracepoint_error() local
545 str = "can't access trace events"; in tracepoint_error()
548 str = "unknown tracepoint"; in tracepoint_error()
551 str = "failed to add tracepoint"; in tracepoint_error()
556 parse_events__handle_error(e, 0, strdup(str), strdup(help)); in tracepoint_error()
1092 if (strcmp(term->val.str, "no") && in config_term_common()
1093 parse_branch_str(term->val.str, in config_term_common()
1261 __t->val.str = strdup(__val); \ in get_config_terms()
1262 if (!__t->val.str) { \ in get_config_terms()
1283 ADD_CONFIG_TERM_STR(CALLGRAPH, term->val.str, term->weak); in get_config_terms()
1286 ADD_CONFIG_TERM_STR(BRANCH, term->val.str, term->weak); in get_config_terms()
1317 ADD_CONFIG_TERM_STR(DRV_CFG, term->val.str, term->weak); in get_config_terms()
1537 zfree(&pos->val.str); in parse_events_add_pmu()
1566 char *str, struct list_head **listp) in parse_events_multi_pmu_add() argument
1583 if (!strcasecmp(alias->name, str)) { in parse_events_multi_pmu_add()
1591 config = strdup(str); in parse_events_multi_pmu_add()
1607 pr_debug("%s -> %s/%s/\n", str, in parse_events_multi_pmu_add()
1608 pmu->name, alias->str); in parse_events_multi_pmu_add()
1788 static int get_event_modifier(struct event_modifier *mod, char *str, in get_event_modifier() argument
1809 while (*str) { in get_event_modifier()
1810 if (*str == 'u') { in get_event_modifier()
1816 } else if (*str == 'k') { in get_event_modifier()
1820 } else if (*str == 'h') { in get_event_modifier()
1824 } else if (*str == 'G') { in get_event_modifier()
1828 } else if (*str == 'H') { in get_event_modifier()
1832 } else if (*str == 'I') { in get_event_modifier()
1834 } else if (*str == 'p') { in get_event_modifier()
1839 } else if (*str == 'P') { in get_event_modifier()
1841 } else if (*str == 'S') { in get_event_modifier()
1843 } else if (*str == 'D') { in get_event_modifier()
1845 } else if (*str == 'e') { in get_event_modifier()
1847 } else if (*str == 'W') { in get_event_modifier()
1852 ++str; in get_event_modifier()
1889 static int check_modifier(char *str) in check_modifier() argument
1891 char *p = str; in check_modifier()
1894 if (strlen(str) > (sizeof("ukhGHpppPSDIWe") - 1)) in check_modifier()
1906 int parse_events__modifier_event(struct list_head *list, char *str, bool add) in parse_events__modifier_event() argument
1911 if (str == NULL) in parse_events__modifier_event()
1914 if (check_modifier(str)) in parse_events__modifier_event()
1917 if (!add && get_event_modifier(&mod, str, NULL)) in parse_events__modifier_event()
1921 if (add && get_event_modifier(&mod, str, evsel)) in parse_events__modifier_event()
1981 #define SET_SYMBOL(str, stype) \ argument
1983 p->symbol = str; \
2095 static int parse_events__scanner(const char *str, in parse_events__scanner() argument
2106 buffer = parse_events__scan_string(str, scanner); in parse_events__scanner()
2123 int parse_events_terms(struct list_head *terms, const char *str) in parse_events_terms() argument
2131 ret = parse_events__scanner(str, &parse_state); in parse_events_terms()
2144 int __parse_events(struct evlist *evlist, const char *str, in __parse_events() argument
2157 ret = parse_events__scanner(str, &parse_state); in __parse_events()
2200 const char *str = "invalid or unsupported event: "; in __parse_events_print_error() local
2220 str = "event syntax error: "; in __parse_events_print_error()
2221 len_str = strlen(str); in __parse_events_print_error()
2244 fprintf(stderr, "%s'%s'\n", str, buf); in __parse_events_print_error()
2258 __parse_events_print_error(err->idx, err->str, err->help, event); in parse_events_print_error()
2259 zfree(&err->str); in parse_events_print_error()
2273 int parse_events_option(const struct option *opt, const char *str, in parse_events_option() argument
2281 ret = parse_events(evlist, str, &err); in parse_events_option()
2284 parse_events_print_error(&err, str); in parse_events_option()
2291 int parse_events_option_new_evlist(const struct option *opt, const char *str, int unset) in parse_events_option_new_evlist() argument
2305 ret = parse_events_option(opt, str, unset); in parse_events_option_new_evlist()
2349 const char *str = arg; in set_filter() local
2361 if (evsel__append_tp_filter(evsel, str) < 0) { in set_filter()
2386 if (evsel__append_addr_filter(evsel, str) < 0) { in set_filter()
2395 int parse_filter(const struct option *opt, const char *str, in parse_filter() argument
2401 (const void *)str); in parse_filter()
2928 char *str, u64 num) in new_term() argument
2945 term->val.str = str; in new_term()
2977 int type_term, char *config, char *str, in parse_events_term__str() argument
2991 return new_term(term, &temp, str, 0); in parse_events_term__str()
2998 char *str; in parse_events_term__sym_hw() local
3013 str = strdup(sym->symbol); in parse_events_term__sym_hw()
3014 if (!str) in parse_events_term__sym_hw()
3016 return new_term(term, &temp, str, 0); in parse_events_term__sym_hw()
3022 char *str; in parse_events_term__clone() local
3039 str = strdup(term->val.str); in parse_events_term__clone()
3040 if (!str) in parse_events_term__clone()
3042 return new_term(new, &temp, str, 0); in parse_events_term__clone()
3051 zfree(&term->val.str); in parse_events_term__delete()
3106 int idx, const char *str) in parse_events_evlist_error() argument
3111 parse_events__handle_error(parse_state->error, idx, strdup(str), NULL); in parse_events_evlist_error()
3147 char *str; in parse_events_formats_error_string() local
3155 if (asprintf(&str, "valid terms: %s,%s", in parse_events_formats_error_string()
3159 if (asprintf(&str, "valid terms: %s", static_terms) < 0) in parse_events_formats_error_string()
3162 return str; in parse_events_formats_error_string()