Home
last modified time | relevance | path

Searched refs:fmt (Results 1 – 25 of 89) sorted by relevance

1234

/tools/perf/util/
Ddebug.h20 #define pr_fmt(fmt) fmt argument
23 #define pr_err(fmt, ...) \ argument
24 eprintf(0, verbose, pr_fmt(fmt), ##__VA_ARGS__)
25 #define pr_warning(fmt, ...) \ argument
26 eprintf(0, verbose, pr_fmt(fmt), ##__VA_ARGS__)
27 #define pr_info(fmt, ...) \ argument
28 eprintf(0, verbose, pr_fmt(fmt), ##__VA_ARGS__)
29 #define pr_debug(fmt, ...) \ argument
30 eprintf(1, verbose, pr_fmt(fmt), ##__VA_ARGS__)
31 #define pr_debugN(n, fmt, ...) \ argument
[all …]
Dcolor.c52 const char *fmt, va_list args, const char *trail) in __color_vsnprintf() argument
68 r += vscnprintf(bf + r, size - r, fmt, args); in __color_vsnprintf()
77 static int __color_vfprintf(FILE *fp, const char *color, const char *fmt, in __color_vfprintf() argument
94 r += vfprintf(fp, fmt, args); in __color_vfprintf()
101 const char *fmt, va_list args) in color_vsnprintf() argument
103 return __color_vsnprintf(bf, size, color, fmt, args, NULL); in color_vsnprintf()
106 int color_vfprintf(FILE *fp, const char *color, const char *fmt, va_list args) in color_vfprintf() argument
108 return __color_vfprintf(fp, color, fmt, args); in color_vfprintf()
112 const char *fmt, ...) in color_snprintf() argument
117 va_start(args, fmt); in color_snprintf()
[all …]
Ddebug.c32 int veprintf(int level, int var, const char *fmt, va_list args) in veprintf() argument
38 ui_helpline__vshow(fmt, args); in veprintf()
40 ret = vfprintf(stderr, fmt, args); in veprintf()
46 int eprintf(int level, int var, const char *fmt, ...) in eprintf() argument
51 va_start(args, fmt); in eprintf()
52 ret = veprintf(level, var, fmt, args); in eprintf()
58 static int veprintf_time(u64 t, const char *fmt, va_list args) in veprintf_time() argument
69 ret += vfprintf(stderr, fmt, args); in veprintf_time()
73 int eprintf_time(int level, int var, u64 t, const char *fmt, ...) in eprintf_time() argument
79 va_start(args, fmt); in eprintf_time()
[all …]
Dcolor.h37 const char *fmt, va_list args);
38 int color_vfprintf(FILE *fp, const char *color, const char *fmt, va_list args);
39 int color_fprintf(FILE *fp, const char *color, const char *fmt, ...);
40 int color_snprintf(char *bf, size_t size, const char *color, const char *fmt, ...);
42 int value_color_snprintf(char *bf, size_t size, const char *fmt, double value);
43 int percent_color_snprintf(char *bf, size_t size, const char *fmt, ...);
44 int percent_color_len_snprintf(char *bf, size_t size, const char *fmt, ...);
45 int percent_color_fprintf(FILE *fp, const char *fmt, double percent);
Dhist.h157 struct perf_hpp_fmt *fmt, int printed);
236 int (*header)(struct perf_hpp_fmt *fmt, struct perf_hpp *hpp,
238 int (*width)(struct perf_hpp_fmt *fmt, struct perf_hpp *hpp,
240 int (*color)(struct perf_hpp_fmt *fmt, struct perf_hpp *hpp,
242 int (*entry)(struct perf_hpp_fmt *fmt, struct perf_hpp *hpp,
244 int64_t (*cmp)(struct perf_hpp_fmt *fmt,
246 int64_t (*collapse)(struct perf_hpp_fmt *fmt,
248 int64_t (*sort)(struct perf_hpp_fmt *fmt,
251 void (*free)(struct perf_hpp_fmt *fmt);
353 bool perf_hpp__defined_dynamic_entry(struct perf_hpp_fmt *fmt, struct hists *hists);
[all …]
Dsort.c42 static int repsep_snprintf(char *bf, size_t size, const char *fmt, ...) in repsep_snprintf() argument
47 va_start(ap, fmt); in repsep_snprintf()
48 n = vsnprintf(bf, size, fmt, ap); in repsep_snprintf()
1599 struct perf_hpp_fmt *fmt; member
1603 #define DIM(d, n) { .name = n, .fmt = &perf_hpp__format[d], }
1623 void perf_hpp__reset_sort_width(struct perf_hpp_fmt *fmt, struct hists *hists) in perf_hpp__reset_sort_width() argument
1627 if (!perf_hpp__is_sort_entry(fmt)) in perf_hpp__reset_sort_width()
1630 hse = container_of(fmt, struct hpp_sort_entry, hpp); in perf_hpp__reset_sort_width()
1631 hists__new_col_len(hists, hse->se->se_width_idx, strlen(fmt->name)); in perf_hpp__reset_sort_width()
1634 static int __sort__hpp_header(struct perf_hpp_fmt *fmt, struct perf_hpp *hpp, in __sort__hpp_header() argument
[all …]
Dpath.c47 char *mkpath(const char *fmt, ...) in mkpath() argument
53 va_start(args, fmt); in mkpath()
54 len = vsnprintf(pathname, PATH_MAX, fmt, args); in mkpath()
Dstrbuf.c88 static int strbuf_addv(struct strbuf *sb, const char *fmt, va_list ap) in strbuf_addv() argument
100 len = vsnprintf(sb->buf + sb->len, sb->alloc - sb->len, fmt, ap); in strbuf_addv()
111 len = vsnprintf(sb->buf + sb->len, sb->alloc - sb->len, fmt, ap_saved); in strbuf_addv()
122 int strbuf_addf(struct strbuf *sb, const char *fmt, ...) in strbuf_addf() argument
127 va_start(ap, fmt); in strbuf_addf()
128 ret = strbuf_addv(sb, fmt, ap); in strbuf_addf()
/tools/lib/traceevent/
Dparse-utils.c28 void __vwarning(const char *fmt, va_list ap) in __vwarning() argument
35 vfprintf(stderr, fmt, ap); in __vwarning()
40 void __warning(const char *fmt, ...) in __warning() argument
44 va_start(ap, fmt); in __warning()
45 __vwarning(fmt, ap); in __warning()
49 void __weak warning(const char *fmt, ...) in warning() argument
53 va_start(ap, fmt); in warning()
54 __vwarning(fmt, ap); in warning()
58 void __vpr_stat(const char *fmt, va_list ap) in __vpr_stat() argument
60 vprintf(fmt, ap); in __vpr_stat()
[all …]
Devent-utils.h26 void warning(const char *fmt, ...);
27 void pr_stat(const char *fmt, ...);
28 void vpr_stat(const char *fmt, va_list ap);
31 void __warning(const char *fmt, ...);
32 void __pr_stat(const char *fmt, ...);
34 void __vwarning(const char *fmt, ...);
35 void __vpr_stat(const char *fmt, ...);
/tools/perf/ui/
Dhist.c14 #define hpp__call_print_fn(hpp, fn, fmt, ...) \ argument
16 int __ret = fn(hpp, fmt, ##__VA_ARGS__); \
22 hpp_field_fn get_field, const char *fmt, int len, in __hpp__fmt() argument
38 ret = hpp__call_print_fn(hpp, print_fn, fmt, len, percent); in __hpp__fmt()
40 ret = hpp__call_print_fn(hpp, print_fn, fmt, len, get_field(he)); in __hpp__fmt()
66 fmt, len, 0.0); in __hpp__fmt()
69 fmt, len, 0ULL); in __hpp__fmt()
74 ret += hpp__call_print_fn(hpp, print_fn, fmt, len, in __hpp__fmt()
77 ret += hpp__call_print_fn(hpp, print_fn, fmt, in __hpp__fmt()
92 fmt, len, 0.0); in __hpp__fmt()
[all …]
Dhelpline.c21 static int nop_helpline__show(const char *fmt __maybe_unused, in nop_helpline__show()
45 void ui_helpline__vpush(const char *fmt, va_list ap) in ui_helpline__vpush() argument
49 if (vasprintf(&s, fmt, ap) < 0) in ui_helpline__vpush()
50 vfprintf(stderr, fmt, ap); in ui_helpline__vpush()
57 void ui_helpline__fpush(const char *fmt, ...) in ui_helpline__fpush() argument
61 va_start(ap, fmt); in ui_helpline__fpush()
62 ui_helpline__vpush(fmt, ap); in ui_helpline__fpush()
72 int ui_helpline__vshow(const char *fmt, va_list ap) in ui_helpline__vshow() argument
74 return helpline_fns->show(fmt, ap); in ui_helpline__vshow()
77 void ui_helpline__printf(const char *fmt, ...) in ui_helpline__printf() argument
[all …]
Dhelpline.h13 int (*show)(const char *fmt, va_list ap);
22 void ui_helpline__vpush(const char *fmt, va_list ap);
23 void ui_helpline__fpush(const char *fmt, ...);
25 void ui_helpline__printf(const char *fmt, ...);
26 int ui_helpline__vshow(const char *fmt, va_list ap);
/tools/lib/api/
Ddebug-internal.h7 #define __pr(func, fmt, ...) \ argument
10 (func)("libapi: " fmt, ##__VA_ARGS__); \
17 #define pr_warning(fmt, ...) __pr(__pr_warning, fmt, ##__VA_ARGS__) argument
18 #define pr_info(fmt, ...) __pr(__pr_info, fmt, ##__VA_ARGS__) argument
19 #define pr_debug(fmt, ...) __pr(__pr_debug, fmt, ##__VA_ARGS__) argument
/tools/perf/pmu-events/
Djson.h18 extern int eprintf(int level, int var, const char *fmt, ...);
19 #define pr_fmt(fmt) fmt argument
21 #define pr_err(fmt, ...) \ argument
22 eprintf(0, verbose, pr_fmt(fmt), ##__VA_ARGS__)
24 #define pr_info(fmt, ...) \ argument
25 eprintf(1, verbose, pr_fmt(fmt), ##__VA_ARGS__)
27 #define pr_debug(fmt, ...) \ argument
28 eprintf(2, verbose, pr_fmt(fmt), ##__VA_ARGS__)
/tools/usb/usbip/libsrc/
Dusbip_common.h52 #define pr_fmt(fmt) "%s: %s: " fmt "\n", PROGNAME argument
53 #define dbg_fmt(fmt) pr_fmt("%s:%d:[%s] " fmt), "debug", \ argument
56 #define err(fmt, args...) \ argument
59 syslog(LOG_ERR, pr_fmt(fmt), "error", ##args); \
62 fprintf(stderr, pr_fmt(fmt), "error", ##args); \
66 #define info(fmt, args...) \ argument
69 syslog(LOG_INFO, pr_fmt(fmt), "info", ##args); \
72 fprintf(stderr, pr_fmt(fmt), "info", ##args); \
76 #define dbg(fmt, args...) \ argument
80 syslog(LOG_DEBUG, dbg_fmt(fmt), ##args); \
[all …]
/tools/perf/
Dbuiltin-diff.c43 struct perf_hpp_fmt fmt; member
54 struct diff_hpp_fmt fmt[PERF_HPP_DIFF__MAX_INDEX]; member
399 static struct data__file *fmt_to_data_file(struct perf_hpp_fmt *fmt) in fmt_to_data_file() argument
401 struct diff_hpp_fmt *dfmt = container_of(fmt, struct diff_hpp_fmt, fmt); in fmt_to_data_file()
403 struct data__file *d = container_of(ptr, struct data__file, fmt); in fmt_to_data_file()
425 struct data__file *d = fmt_to_data_file(&dfmt->fmt); in get_pair_fmt()
606 hist_entry__cmp_nop(struct perf_hpp_fmt *fmt __maybe_unused, in hist_entry__cmp_nop()
614 hist_entry__cmp_baseline(struct perf_hpp_fmt *fmt __maybe_unused, in hist_entry__cmp_baseline()
623 hist_entry__cmp_delta(struct perf_hpp_fmt *fmt, in hist_entry__cmp_delta() argument
626 struct data__file *d = fmt_to_data_file(fmt); in hist_entry__cmp_delta()
[all …]
Dbuiltin-c2c.c358 int64_t (*cmp)(struct perf_hpp_fmt *fmt,
360 int (*entry)(struct perf_hpp_fmt *fmt, struct perf_hpp *hpp,
362 int (*color)(struct perf_hpp_fmt *fmt, struct perf_hpp *hpp,
367 struct perf_hpp_fmt fmt; member
386 static int c2c_width(struct perf_hpp_fmt *fmt, in c2c_width() argument
393 c2c_fmt = container_of(fmt, struct c2c_fmt, fmt); in c2c_width()
403 static int c2c_header(struct perf_hpp_fmt *fmt, struct perf_hpp *hpp, in c2c_header() argument
410 int width = c2c_width(fmt, hpp, hists); in c2c_header()
412 c2c_fmt = container_of(fmt, struct c2c_fmt, fmt); in c2c_header()
444 dcacheline_cmp(struct perf_hpp_fmt *fmt __maybe_unused, in dcacheline_cmp()
[all …]
/tools/lib/
Dvsprintf.c6 int vscnprintf(char *buf, size_t size, const char *fmt, va_list args) in vscnprintf() argument
8 int i = vsnprintf(buf, size, fmt, args); in vscnprintf()
14 int scnprintf(char * buf, size_t size, const char * fmt, ...) in scnprintf() argument
20 va_start(args, fmt); in scnprintf()
21 i = vsnprintf(buf, size, fmt, args); in scnprintf()
/tools/perf/ui/gtk/
Dhists.c14 static int __percent_color_snprintf(struct perf_hpp *hpp, const char *fmt, ...) in __percent_color_snprintf() argument
24 va_start(args, fmt); in __percent_color_snprintf()
33 ret += scnprintf(buf + ret, size - ret, fmt, len, percent); in __percent_color_snprintf()
47 static int perf_gtk__hpp_color_##_type(struct perf_hpp_fmt *fmt, \
51 return hpp__fmt(fmt, hpp, he, he_get_##_field, " %*.2f%%", \
61 static int perf_gtk__hpp_color_##_type(struct perf_hpp_fmt *fmt, \
65 return hpp__fmt_acc(fmt, hpp, he, he_get_acc_##_field, " %*.2f%%", \
294 struct perf_hpp_fmt *fmt; in perf_gtk__show_hists() local
312 hists__for_each_format(hists, fmt) in perf_gtk__show_hists()
323 hists__for_each_format(hists, fmt) { in perf_gtk__show_hists()
[all …]
/tools/perf/ui/stdio/
Dhist.c478 struct perf_hpp_fmt *fmt; in __hist_entry__snprintf() local
486 perf_hpp_list__for_each_format(hpp_list, fmt) { in __hist_entry__snprintf()
487 if (perf_hpp__should_skip(fmt, he->hists)) in __hist_entry__snprintf()
500 if (perf_hpp__use_color() && fmt->color) in __hist_entry__snprintf()
501 ret = fmt->color(fmt, hpp, he); in __hist_entry__snprintf()
503 ret = fmt->entry(fmt, hpp, he); in __hist_entry__snprintf()
505 ret = hist_entry__snprintf_alignment(he, hpp, fmt, ret); in __hist_entry__snprintf()
523 struct perf_hpp_fmt *fmt; in hist_entry__hierarchy_fprintf() local
539 perf_hpp_list__for_each_format(&fmt_node->hpp, fmt) { in hist_entry__hierarchy_fprintf()
550 if (perf_hpp__use_color() && fmt->color) in hist_entry__hierarchy_fprintf()
[all …]
/tools/net/
Dbpf_dbg.c173 static __check_format_printf(1, 2) int rl_printf(const char *fmt, ...) in rl_printf() argument
178 va_start(vl, fmt); in rl_printf()
179 ret = vfprintf(rl_outstream, fmt, vl); in rl_printf()
218 const char *op, *fmt; in bpf_disasm() local
225 fmt = "#%#x"; in bpf_disasm()
229 fmt = "a"; in bpf_disasm()
233 fmt = "x"; in bpf_disasm()
237 fmt = ""; in bpf_disasm()
241 fmt = ""; in bpf_disasm()
245 fmt = "M[%d]"; in bpf_disasm()
[all …]
/tools/testing/selftests/mount/
Dunprivileged-remount-test.c48 static void die(char *fmt, ...) in die() argument
51 va_start(ap, fmt); in die()
52 vfprintf(stderr, fmt, ap); in die()
57 static void vmaybe_write_file(bool enoent_ok, char *filename, char *fmt, va_list ap) in vmaybe_write_file() argument
64 buf_len = vsnprintf(buf, sizeof(buf), fmt, ap); in vmaybe_write_file()
95 static void maybe_write_file(char *filename, char *fmt, ...) in maybe_write_file() argument
99 va_start(ap, fmt); in maybe_write_file()
100 vmaybe_write_file(true, filename, fmt, ap); in maybe_write_file()
105 static void write_file(char *filename, char *fmt, ...) in write_file() argument
109 va_start(ap, fmt); in write_file()
[all …]
/tools/perf/scripts/python/
Dexport-to-postgresql.py674 fmt = "!hiqi" + str(n) + "s"
675 value = struct.pack(fmt, 2, 8, evsel_id, n, evsel_name)
680 fmt = "!hiqiii" + str(n) + "s"
681 value = struct.pack(fmt, 3, 8, machine_id, 4, pid, n, root_dir)
690 fmt = "!hiqi" + str(n) + "s"
691 value = struct.pack(fmt, 2, 8, comm_id, n, comm_str)
695 fmt = "!hiqiqiq"
696 value = struct.pack(fmt, 3, 8, comm_thread_id, 8, comm_id, 8, thread_id)
703 fmt = "!hiqiqi" + str(n1) + "si" + str(n2) + "si" + str(n3) + "s"
704 value = struct.pack(fmt, 5, 8, dso_id, 8, machine_id, n1, short_name, n2, long_name, n3, build_id)
[all …]
/tools/perf/util/intel-pt-decoder/
Dintel-pt-log.h38 void __intel_pt_log(const char *fmt, ...) __printf(1, 2);
40 #define intel_pt_log(fmt, ...) \ argument
43 __intel_pt_log(fmt, ##__VA_ARGS__); \

1234