mbox series

[v3,00/11] libtracefs dynamic events support

Message ID 20211103154417.246999-1-tz.stoyanov@gmail.com (mailing list archive)
Headers show
Series libtracefs dynamic events support | expand

Message

Tzvetomir Stoyanov (VMware) Nov. 3, 2021, 3:44 p.m. UTC
The libtracefs logic that works with ftrace dynamic events is unified
and capsulated into a new set of dynamic events APIs. This change makes
the code more consistent and reusable. Also, adding future libtracefs
support for uprobes and eprobes dynamic events is simplified.
The existing library APIs for kprobes and synthetic events are
reimplemented using the new dynamic events helpers.

Suggested-by: Yordan Karadzhov (VMware) <y.karadz@gmail.com>

v3 changes:
 - Exposed dynamic events API as official tracefs APIs.
 - Removed kprobe specific APIs, that duplicate corresponding dynamic events
   APIs.
 - Updated unit tests and man pages with the new dynamic events APIs.
 - Fixed typos, found by Yordan. 

v2 changes:
 - Removed triple pointer from the APIs.
 - Reimplement dynamic events parsing using strtok_r instead of strchr.
 - Coding style fixes.

Tzvetomir Stoyanov (VMware) (11):
  libtracefs: Add new public macros for bits manipulations
  libtracefs: New APIs for dynamic events
  libtracefs: New APIs for kprobe allocation
  libtracefs: Remove redundant kprobes APIs
  libtracefs: Change tracefs_kprobe_info API
  libtracefs: Reimplement kprobe raw APIs
  libtracefs: Extend kprobes unit test
  libtracefs: Rename tracefs_synth_init API
  libtracefs: Use the internal dynamic events API when creating
    synthetic events
  libtracefs: Update kprobes man pages
  libtracefs: Document dynamic events APIs

 Documentation/libtracefs-dynevents.txt | 257 +++++++++++
 Documentation/libtracefs-kprobes.txt   | 111 +++--
 Documentation/libtracefs-synth.txt     |  20 +-
 Documentation/libtracefs-synth2.txt    |  10 +-
 Documentation/libtracefs.txt           |  17 +
 include/tracefs-local.h                |  18 +
 include/tracefs.h                      |  58 ++-
 src/Makefile                           |   1 +
 src/tracefs-dynevents.c                | 601 +++++++++++++++++++++++++
 src/tracefs-hist.c                     | 125 +++--
 src/tracefs-kprobes.c                  | 545 +++++++---------------
 src/tracefs-sqlhist.c                  |   6 +-
 utest/tracefs-utest.c                  | 417 ++++++++++-------
 13 files changed, 1479 insertions(+), 707 deletions(-)
 create mode 100644 Documentation/libtracefs-dynevents.txt
 create mode 100644 src/tracefs-dynevents.c