linux-perf-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v5 0/8] perf trace: Augment enum arguments with BTF
@ 2024-07-05 13:20 Howard Chu
  2024-07-05 13:20 ` [PATCH v5 1/8] perf trace: Fix iteration of syscall ids in syscalltbl->entries Howard Chu
                   ` (9 more replies)
  0 siblings, 10 replies; 37+ messages in thread
From: Howard Chu @ 2024-07-05 13:20 UTC (permalink / raw)
  To: acme
  Cc: adrian.hunter, irogers, jolsa, kan.liang, namhyung,
	linux-perf-users, linux-kernel

Changes in v5:

- Use hardcoded landlock structs and macros for landlock.c workload to
make this build in older systems.

Changes in v4:

- Fix landlock workload's build error.

Changes in v3:

- Add trace__btf_scnprintf() helper function
- Remove is_enum memeber in struct syscall_arg_fmt, replace it with 
btf_is_enum()
- Add syscall_arg_fmt__cache_btf_enum() to cache btf_type only
- Resolve NO_LIBBPF=1 build error
- Skip BTF augmentation test if landlock_add_rule syscall and LIBBPF are not
available
- Rename landlock.c workload, add a comment to landlock.c workload
- Change the way of skipping 'enum ' prefix
- Add type_name member to struct syscall_arg

Changes in v2:

- Add trace_btf_enum regression test, and landlock workload

v1:

In this patch, BTF is used to turn enum value to the corresponding
enum variable name. There is only one system call that uses enum value
as its argument, that is `landlock_add_rule()`.

Enum arguments of non-syscall tracepoints can also be augmented, for
instance timer:hrtimer_start and timer:hrtimer_init's 'mode' argument.


Arnaldo Carvalho de Melo (2):
  perf trace: Introduce trace__btf_scnprintf()
  perf trace: Remove arg_fmt->is_enum, we can get that from the BTF type

Howard Chu (6):
  perf trace: Fix iteration of syscall ids in syscalltbl->entries
  perf trace: BTF-based enum pretty printing for syscall args
  perf trace: Augment non-syscall tracepoints with enum arguments with
    BTF
  perf trace: Filter enum arguments with enum names
  perf test: Add landlock workload
  perf test trace_btf_enum: Add regression test for the BTF augmentation
    of enums in 'perf trace'

 tools/perf/builtin-trace.c               | 229 ++++++++++++++++++++---
 tools/perf/tests/builtin-test.c          |   1 +
 tools/perf/tests/shell/trace_btf_enum.sh |  61 ++++++
 tools/perf/tests/tests.h                 |   1 +
 tools/perf/tests/workloads/Build         |   2 +
 tools/perf/tests/workloads/landlock.c    |  66 +++++++
 tools/perf/trace/beauty/beauty.h         |   1 +
 tools/perf/util/syscalltbl.c             |   7 +
 tools/perf/util/syscalltbl.h             |   1 +
 9 files changed, 345 insertions(+), 24 deletions(-)
 create mode 100755 tools/perf/tests/shell/trace_btf_enum.sh
 create mode 100644 tools/perf/tests/workloads/landlock.c

-- 
2.45.2


^ permalink raw reply	[flat|nested] 37+ messages in thread

end of thread, other threads:[~2024-10-22 15:18 UTC | newest]

Thread overview: 37+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-05 13:20 [PATCH v5 0/8] perf trace: Augment enum arguments with BTF Howard Chu
2024-07-05 13:20 ` [PATCH v5 1/8] perf trace: Fix iteration of syscall ids in syscalltbl->entries Howard Chu
2024-07-12 16:51   ` Namhyung Kim
2024-08-30 10:24   ` Jiri Slaby
2024-08-30 10:27     ` Jiri Slaby
2024-08-30 23:30     ` [PATCH/RFT] " Arnaldo Carvalho de Melo
2024-08-31  0:35       ` Ian Rogers
2024-09-02 18:53         ` Arnaldo Carvalho de Melo
2024-09-02  5:25       ` Jiri Slaby
2024-09-02 18:54         ` Arnaldo Carvalho de Melo
2024-09-27  5:09           ` Jiri Slaby
2024-10-08  9:09             ` Jiri Slaby
2024-10-09  5:57               ` Namhyung Kim
     [not found]                 ` <CAH0uvoi622J7gZ9BoTik7niNH3axVJR0kPNovUQnMjUB6GWLNg@mail.gmail.com>
2024-10-09  6:58                   ` Howard Chu
2024-10-10  8:22                     ` Jiri Slaby
2024-10-10 16:29                       ` Namhyung Kim
2024-10-10 16:31                         ` Namhyung Kim
2024-10-10 21:02                           ` Arnaldo Carvalho de Melo
2024-10-14 12:19                             ` Jiri Slaby
     [not found]                               ` <CA+JHD937angqu=48-kPC7LvtMMQPgUGp+2x5b+JKVNoFa3+9HQ@mail.gmail.com>
2024-10-14 13:04                                 ` Jiri Slaby
2024-10-14 13:06                                   ` Jiri Slaby
2024-10-14 13:12                                   ` Jiri Slaby
2024-10-18 22:16                               ` Arnaldo Carvalho de Melo
2024-10-18 22:26                                 ` Arnaldo Carvalho de Melo
2024-10-21  5:43                                   ` Jiri Slaby
2024-10-22 15:18                                     ` Arnaldo Carvalho de Melo
2024-10-10  8:11                 ` Jiri Slaby
2024-10-10 16:19                   ` Namhyung Kim
2024-07-05 13:20 ` [PATCH v5 2/8] perf trace: BTF-based enum pretty printing for syscall args Howard Chu
2024-07-05 13:20 ` [PATCH v5 3/8] perf trace: Augment non-syscall tracepoints with enum arguments with BTF Howard Chu
2024-07-05 13:20 ` [PATCH v5 4/8] perf trace: Filter enum arguments with enum names Howard Chu
2024-07-05 13:20 ` [PATCH v5 5/8] perf test: Add landlock workload Howard Chu
2024-07-05 13:20 ` [PATCH v5 6/8] perf test trace_btf_enum: Add regression test for the BTF augmentation of enums in 'perf trace' Howard Chu
2024-07-05 13:20 ` [PATCH v5 7/8] perf trace: Introduce trace__btf_scnprintf() Howard Chu
2024-07-05 13:20 ` [PATCH v5 8/8] perf trace: Remove arg_fmt->is_enum, we can get that from the BTF type Howard Chu
2024-07-10 18:02 ` [PATCH v5 0/8] perf trace: Augment enum arguments with BTF Ian Rogers
2024-07-13 15:06 ` Namhyung Kim

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).