Skip to content

libtraceevent: Optimize the print of tep fields

Yordan Karadzhov (VMware) linux-trace-devel 7 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v8 Latest2 patches 0 repliesNew
  2. v74 patches 2 repliesSuperseded
  3. v65 patches 7 repliesSuperseded
Earlier versions · 4
VersionPostedPatchesRepliesStatus
v55 patches2 repliesSuperseded
v45 patches0 repliesSuperseded
v32 patches0 repliesSuperseded
v22 patches2 repliesSuperseded

Changes in v8 from the cover letter

- In tep_record_print_selected_fields(), changing the argument 'ignore_mask' to 'select_maks'.
- Fixes in the documentation of the new APIs.

Patches in v8 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2libtraceevent: Add APIs for printing the fields of a recordsrc/event-parse.c src/event-parse.h+54 -40 replies
2/2libtraceevent: Add documentation for the new printing APIsDocumentation/libtraceevent-field_print.txt Documentation/libtraceevent.txt+12 -10 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v8 yet.

Read the v8 thread

Cover letter [PATCH v8 0/2] libtraceevent: Optimize the print of tep fields

Provide new capabilities for printing the content of the individual fields of the event.

Changes in v8:
- In tep_record_print_selected_fields(), changing the argument 'ignore_mask' to 'select_maks'.
- Fixes in the documentation of the new APIs.

Changes in v7:
- Proper naming (without 'tep' prefix) of the static methods defined in the patches.
- Fixing the 'for' loop in print_selected_fields()
- 'tep_print_selected_fields()' was renamed to 'tep_record_print_selected_fields()'. 'tep_record_print_fields()' was added.
- Adding documentation for the new APIs.

Changes in v6:
- Cleanup in [PATCH 1/5].
- Protection against infinite loop in _tep_print_field() ([PATCH 4/5]).

Changes in v5:
- The loop over the tokens in _tep_print_field() is made circular in order to support the corner case when the fields and the tokens are listed in different order.
- _tep_print_field() and print_selected_fields() are made "inline" in order to help the compiler to optimize out the unused variables (suggested by Steven).

Changes in v4:
- Directly applying the modification in tep_print_field() suggested by Steven.
- Optimizing the loop over the tokens in tep_print_fields().

Yordan Karadzhov (VMware) (2):
libtraceevent: Add APIs for printing the fields of a record
libtraceevent: Add documentation for the new printing APIs

 Documentation/libtraceevent-field_print.txt | 11 ++++-
 Documentation/libtraceevent.txt             |  2 +
 src/event-parse.c                           | 51 +++++++++++++++++++--
 src/event-parse.h                           |  7 +++
 4 files changed, 66 insertions(+), 5 deletions(-)
Signature · 1 line
2.30.2