Home
last modified time | relevance | path

Searched refs:str (Results 1 – 25 of 228) sorted by relevance

12345678910

/tools/testing/selftests/bpf/progs/
Dnetif_receive_skb.c104 char *str; in BPF_PROG() local
107 str = bpf_map_lookup_elem(&strdata, &key); in BPF_PROG()
108 if (!str) in BPF_PROG()
116 ret = bpf_snprintf_btf(str, STRSIZE, &p, sizeof(p), 0); in BPF_PROG()
124 __ret = bpf_snprintf_btf(str, STRSIZE, &p, sizeof(p), 0); in BPF_PROG()
134 TEST_BTF_C(str, int, 0, 1234); in BPF_PROG()
135 TEST_BTF(str, int, BTF_F_NONAME, "1234", 1234); in BPF_PROG()
137 TEST_BTF(str, int, 0, "(int)0", 0); in BPF_PROG()
138 TEST_BTF(str, int, BTF_F_NONAME, "0", 0); in BPF_PROG()
139 TEST_BTF(str, int, BTF_F_ZERO, "(int)0", 0); in BPF_PROG()
[all …]
/tools/perf/util/
Ddemangle-rust.c100 static bool is_prefixed_hash(const char *str) in is_prefixed_hash() argument
107 if (strncmp(str, hash_prefix, hash_prefix_len)) in is_prefixed_hash()
109 str += hash_prefix_len; in is_prefixed_hash()
112 for (end = str + hash_len; str < end; str++) in is_prefixed_hash()
113 if (*str >= '0' && *str <= '9') in is_prefixed_hash()
114 seen[*str - '0'] = true; in is_prefixed_hash()
115 else if (*str >= 'a' && *str <= 'f') in is_prefixed_hash()
116 seen[*str - 'a' + 10] = true; in is_prefixed_hash()
129 static bool looks_like_rust(const char *str, size_t len) in looks_like_rust() argument
131 const char *end = str + len; in looks_like_rust()
[all …]
Dstring.c24 s64 perf_atoll(const char *str) in perf_atoll() argument
30 if (!isdigit(str[0])) in perf_atoll()
33 length = strtoll(str, &p, 10); in perf_atoll()
111 static bool __match_glob(const char *str, const char *pat, bool ignore_space, in __match_glob() argument
114 while (*str && *pat && *pat != '*') { in __match_glob()
117 if (isspace(*str)) { in __match_glob()
118 str++; in __match_glob()
127 str++; in __match_glob()
131 if (__match_charclass(pat + 1, *str, &pat)) { in __match_glob()
132 str++; in __match_glob()
[all …]
Dexpr.l13 static double __value(YYSTYPE *yylval, char *str, int token) in __value() argument
18 num = strtod(str, NULL); in __value()
38 static char *normalize(char *str, int runtime) in normalize() argument
40 char *ret = str; in normalize()
41 char *dst = str; in normalize()
43 while (*str) { in normalize()
44 if (*str == '@') in normalize()
46 else if (*str == '\\') in normalize()
47 *dst++ = *++str; in normalize()
48 else if (*str == '?') { in normalize()
[all …]
Dcomm.c13 char *str; member
36 zfree(&cs->str); in comm_str__put()
41 static struct comm_str *comm_str__alloc(const char *str) in comm_str__alloc() argument
49 cs->str = strdup(str); in comm_str__alloc()
50 if (!cs->str) { in comm_str__alloc()
61 struct comm_str *__comm_str__findnew(const char *str, struct rb_root *root) in __comm_str__findnew() argument
77 cmp = strcmp(str, iter->str); in __comm_str__findnew()
87 new = comm_str__alloc(str); in __comm_str__findnew()
97 static struct comm_str *comm_str__findnew(const char *str, struct rb_root *root) in comm_str__findnew() argument
102 cs = __comm_str__findnew(str, root); in comm_str__findnew()
[all …]
Dstring2.h14 s64 perf_atoll(const char *str);
15 bool strglobmatch(const char *str, const char *pat);
16 bool strglobmatch_nocase(const char *str, const char *pat);
17 bool strlazymatch(const char *str, const char *pat);
18 static inline bool strisglob(const char *str) in strisglob() argument
20 return strpbrk(str, "*?[") != NULL; in strisglob()
38 char *strpbrk_esc(char *str, const char *stopset);
39 char *strdup_esc(const char *str);
Dtime-utils.c18 int parse_nsec_time(const char *str, u64 *ptime) in parse_nsec_time() argument
23 time_sec = strtoul(str, &end, 10); in parse_nsec_time()
70 char *d, *str; in split_start_end() local
76 str = strdup(ostr); in split_start_end()
77 if (str == NULL) in split_start_end()
80 start_str = str; in split_start_end()
124 char *str, *arg, *p; in perf_time__parse_strs() local
136 str = strdup(ostr); in perf_time__parse_strs()
137 if (!str) in perf_time__parse_strs()
141 for (i = 0, p = str; i < num - 1; i++) { in perf_time__parse_strs()
[all …]
Dparse-events.h34 int parse_events_option(const struct option *opt, const char *str, int unset);
35 int parse_events_option_new_evlist(const struct option *opt, const char *str, int unset);
36 int __parse_events(struct evlist *evlist, const char *str, struct parse_events_error *error,
39 static inline int parse_events(struct evlist *evlist, const char *str, in parse_events() argument
42 return __parse_events(evlist, str, err, NULL); in parse_events()
45 int parse_events_terms(struct list_head *terms, const char *str);
46 int parse_filter(const struct option *opt, const char *str, int unset);
105 char *str; member
125 char *str; /* string to display at the index */ member
144 char *str, char *help);
[all …]
Dparse-regs-options.c13 __parse_regs(const struct option *opt, const char *str, int unset, bool intr) in __parse_regs() argument
36 if (str) { in __parse_regs()
38 s = os = strdup(str); in __parse_regs()
90 parse_user_regs(const struct option *opt, const char *str, int unset) in parse_user_regs() argument
92 return __parse_regs(opt, str, unset, false); in parse_user_regs()
96 parse_intr_regs(const struct option *opt, const char *str, int unset) in parse_intr_regs() argument
98 return __parse_regs(opt, str, unset, true); in parse_intr_regs()
Dsmt.c24 char *str; in smt_on() local
30 if (sysfs__read_str(fn, &str, &strlen) < 0) { in smt_on()
34 if (sysfs__read_str(fn, &str, &strlen) < 0) in smt_on()
38 siblings = strtoull(str, NULL, 16); in smt_on()
39 free(str); in smt_on()
Dcgroup.c38 static struct cgroup *evlist__find_cgroup(struct evlist *evlist, const char *str) in evlist__find_cgroup() argument
47 if (!strcmp(counter->cgrp->name, str)) in evlist__find_cgroup()
90 static int add_cgroup(struct evlist *evlist, const char *str) in add_cgroup() argument
93 struct cgroup *cgrp = evlist__findnew_cgroup(evlist, str); in add_cgroup()
152 int parse_cgroups(const struct option *opt, const char *str, in parse_cgroups() argument
158 const char *p, *e, *eos = str + strlen(str); in parse_cgroups()
168 p = strchr(str, ','); in parse_cgroups()
172 if (e - str) { in parse_cgroups()
174 s = strndup(str, e - str); in parse_cgroups()
186 str = p+1; in parse_cgroups()
[all …]
Dclockid.c68 int parse_clockid(const struct option *opt, const char *str, int unset) in parse_clockid() argument
72 const char *ostr = str; in parse_clockid()
80 if (!str) in parse_clockid()
90 if (sscanf(str, "%d", &opts->clockid) == 1) in parse_clockid()
94 if (!strncasecmp(str, "CLOCK_", 6)) in parse_clockid()
95 str += 6; in parse_clockid()
98 if (!strcasecmp(str, cm->name)) { in parse_clockid()
Ddemangle-java.c45 __demangle_java_sym(const char *str, const char *end, char *buf, int maxlen, int mode) in __demangle_java_sym() argument
53 end = str + strlen(str); in __demangle_java_sym()
55 for (q = str; q != end; q++) { in __demangle_java_sym()
158 java_demangle_sym(const char *str, int flags) in java_demangle_sym() argument
164 if (!str) in java_demangle_sym()
168 p = strrchr(str, ')'); in java_demangle_sym()
175 len = strlen(str) * 3 + 1; in java_demangle_sym()
195 ptr = __demangle_java_sym(str, p + 1, buf + l1, len - l1, MODE_PREFIX); in java_demangle_sym()
Dparse-events.c188 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()
[all …]
/tools/lib/
Dargv_split.c19 static int count_argc(const char *str) in count_argc() argument
23 while (*str) { in count_argc()
24 str = skip_spaces(str); in count_argc()
25 if (*str) { in count_argc()
27 str = skip_arg(str); in count_argc()
63 char **argv_split(const char *str, int *argcp) in argv_split() argument
65 int argc = count_argc(str); in argv_split()
77 while (*str) { in argv_split()
78 str = skip_spaces(str); in argv_split()
80 if (*str) { in argv_split()
[all …]
/tools/perf/arch/arm/tests/
Dregs_load.S41 str r0, [r0, #R0]
42 str r1, [r0, #R1]
43 str r2, [r0, #R2]
44 str r3, [r0, #R3]
45 str r4, [r0, #R4]
46 str r5, [r0, #R5]
47 str r6, [r0, #R6]
48 str r7, [r0, #R7]
49 str r8, [r0, #R8]
50 str r9, [r0, #R9]
[all …]
/tools/perf/
Dbuiltin-probe.c53 static int parse_probe_event(const char *str) in parse_probe_event() argument
58 pr_debug("probe-definition(%d): %s\n", params.nevents, str); in parse_probe_event()
75 ret = parse_perf_probe_command(str, pev); in parse_probe_event()
81 static int params_add_filter(const char *str) in params_add_filter() argument
86 pr_debug2("Add filter: %s\n", str); in params_add_filter()
88 params.filter = strfilter__new(str, &err); in params_add_filter()
92 ret = strfilter__or(params.filter, str, &err); in params_add_filter()
95 pr_err("Filter parse error at %td.\n", err - str + 1); in params_add_filter()
96 pr_err("Source: \"%s\"\n", str); in params_add_filter()
97 pr_err(" %*c\n", (int)(err - str + 1), '^'); in params_add_filter()
[all …]
/tools/testing/selftests/arm64/fp/
Dsve-ptrace-asm.S14 str q0, [x1]
18 str q0, [x1, #0x10]
21 str q0, [x1, #0x20]
25 str q0, [x1, #0x30]
28 str q0, [x1, #0x40]
/tools/bpf/bpftool/
Dnetlink_dumper.h79 #define NET_DUMP_STR(name, fmt_str, str) \ argument
82 jsonw_string_field(json_wtr, name, str);\
84 fprintf(stdout, fmt_str, str); \
87 #define NET_DUMP_STR_ONLY(str) \ argument
90 jsonw_string(json_wtr, str); \
92 fprintf(stdout, "%s ", str); \
/tools/bootconfig/include/linux/
Dstring.h8 static inline char *skip_spaces(const char *str) in skip_spaces() argument
10 while (isspace(*str)) in skip_spaces()
11 ++str; in skip_spaces()
12 return (char *)str; in skip_spaces()
/tools/perf/scripts/python/
Dexport-to-sqlite.py675 q.addBindValue(str(xx))
705 sample_query.addBindValue(str(xx))
707 sample_query.addBindValue(str(xx))
723 ptwrite_query.addBindValue(str(id))
724 ptwrite_query.addBindValue(str(payload))
725 ptwrite_query.addBindValue(str(exact_ip))
733 cbr_query.addBindValue(str(id))
734 cbr_query.addBindValue(str(cbr))
735 cbr_query.addBindValue(str(MHz))
736 cbr_query.addBindValue(str(percent))
[all …]
/tools/lib/traceevent/
Dparse-filter.c205 free(arg->str.val); in free_arg()
206 regfree(&arg->str.reg); in free_arg()
207 free(arg->str.buffer); in free_arg()
213 free(arg->value.str); in free_arg()
351 arg->value.str = strdup(token); in create_arg_item()
352 if (!arg->value.str) { in create_arg_item()
443 char *str; in add_right() local
486 if (strlen(arg->value.str) == 1 && in add_right()
498 str = arg->value.str; in add_right()
533 ret = regcomp(&op->str.reg, str, REG_ICASE|REG_NOSUB); in add_right()
[all …]
/tools/perf/tests/
Dbitmap.c11 static unsigned long *get_bitmap(const char *str, int nbits) in get_bitmap() argument
13 struct perf_cpu_map *map = perf_cpu_map__new(str); in get_bitmap()
29 static int test_bitmap(const char *str) in test_bitmap() argument
31 unsigned long *bm = get_bitmap(str, NBITS); in test_bitmap()
38 ret = !strcmp(buf, str); in test_bitmap()
Dunit_number__scnprintf.c14 const char *str; in test__unit_number__scnprint() member
25 while (test[i].str) { in test__unit_number__scnprint()
31 test[i].n, test[i].str, buf); in test__unit_number__scnprint()
33 if (strcmp(test[i].str, buf)) in test__unit_number__scnprint()
/tools/objtool/
Dwarn.h21 char *name, *str; in offstr() local
33 str = malloc(strlen(name) + 20); in offstr()
36 sprintf(str, "%s()+0x%lx", name, name_off); in offstr()
38 sprintf(str, "%s+0x%lx", name, name_off); in offstr()
40 return str; in offstr()

12345678910