From: "Yordan Karadzhov (VMware)" <y.karadz@gmail.com>
To: rostedt@goodmis.org
Cc: linux-trace-devel@vger.kernel.org,
"Yordan Karadzhov (VMware)" <y.karadz@gmail.com>
Subject: [PATCH v8 2/2] libtraceevent: Add documentation for the new printing APIs
Date: Thu, 9 Sep 2021 11:06:38 +0300 [thread overview]
Message-ID: <20210909080638.259024-3-y.karadz@gmail.com> (raw)
In-Reply-To: <20210909080638.259024-1-y.karadz@gmail.com>
'tep_record_print_fields()' and 'tep_record_print_selected_fields()'
are documented.
Signed-off-by: Yordan Karadzhov (VMware) <y.karadz@gmail.com>
---
Documentation/libtraceevent-field_print.txt | 11 ++++++++++-
Documentation/libtraceevent.txt | 2 ++
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/Documentation/libtraceevent-field_print.txt b/Documentation/libtraceevent-field_print.txt
index 2c2cf6c..c201c13 100644
--- a/Documentation/libtraceevent-field_print.txt
+++ b/Documentation/libtraceevent-field_print.txt
@@ -3,7 +3,7 @@ libtraceevent(3)
NAME
----
-tep_print_field, tep_print_fields, tep_print_num_field, tep_print_func_field -
+tep_print_field, tep_print_fields, tep_print_num_field, tep_print_func_field, tep_record_print_fields, tep_record_print_selected_fields -
Print the field content.
SYNOPSIS
@@ -17,6 +17,8 @@ void *tep_print_field*(struct trace_seq pass:[*]_s_, void pass:[*]_data_, struct
void *tep_print_fields*(struct trace_seq pass:[*]_s_, void pass:[*]_data_, int _size_, struct tep_event pass:[*]_event_);
int *tep_print_num_field*(struct trace_seq pass:[*]_s_, const char pass:[*]_fmt_, struct tep_event pass:[*]_event_, const char pass:[*]_name_, struct tep_record pass:[*]_record_, int _err_);
int *tep_print_func_field*(struct trace_seq pass:[*]_s_, const char pass:[*]_fmt_, struct tep_event pass:[*]_event_, const char pass:[*]_name_, struct tep_record pass:[*]_record_, int _err_);
+void *tep_record_print_fields*(struct trace_seq pass:[*]_s_, struct tep_record pass:[*]_record_, struct tep_event pass:[*]_event_);
+void *tep_record_print_selected_fields*(struct trace_seq pass:[*]_s_, struct tep_record pass:[*]_record_, struct tep_event pass:[*]_event_, int _select_mask_);
--
DESCRIPTION
@@ -49,6 +51,13 @@ function. The function name (if found) and its address are printed in the _s_,
according to the given format string _fmt_. If the argument _err_ is non-zero,
and an error occures - it is printed in _s_.
+The _tep_record_print_fields()_ prints the field's name followed by its value
+for all record's field.
+
+The _tep_record_print_selected_fields()_ prints the field's name followed by
+its value for selected subset of record field. The fields to be printed are
+defined by the _select_mask_ bit mask.
+
RETURN VALUE
------------
The _tep_print_num_field()_ and _tep_print_func_field()_ functions return 1
diff --git a/Documentation/libtraceevent.txt b/Documentation/libtraceevent.txt
index d42b5c9..01014b7 100644
--- a/Documentation/libtraceevent.txt
+++ b/Documentation/libtraceevent.txt
@@ -80,6 +80,8 @@ Event fields printing:
void *tep_print_fields*(struct trace_seq pass:[*]_s_, void pass:[*]_data_, int _size_, struct tep_event pass:[*]_event_);
int *tep_print_num_field*(struct trace_seq pass:[*]_s_, const char pass:[*]_fmt_, struct tep_event pass:[*]_event_, const char pass:[*]_name_, struct tep_record pass:[*]_record_, int _err_);
int *tep_print_func_field*(struct trace_seq pass:[*]_s_, const char pass:[*]_fmt_, struct tep_event pass:[*]_event_, const char pass:[*]_name_, struct tep_record pass:[*]_record_, int _err_);
+ void *tep_record_print_fields*(struct trace_seq pass:[*]_s_, struct tep_record pass:[*]_record_, struct tep_event pass:[*]_event_);
+ void *tep_record_print_selected_fields*(struct trace_seq pass:[*]_s_, struct tep_record pass:[*]_record_, struct tep_event pass:[*]_event_, int _select_mask_);
Event fields finding:
struct tep_format_field pass:[*]*tep_find_common_field*(struct tep_event pass:[*]_event_, const char pass:[*]_name_);
--
2.30.2
prev parent reply other threads:[~2021-09-09 8:06 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-09 8:06 [PATCH v8 0/2] libtraceevent: Optimize the print of tep fields Yordan Karadzhov (VMware)
2021-09-09 8:06 ` [PATCH v8 1/2] libtraceevent: Add APIs for printing the fields of a record Yordan Karadzhov (VMware)
2021-09-09 8:06 ` Yordan Karadzhov (VMware) [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210909080638.259024-3-y.karadz@gmail.com \
--to=y.karadz@gmail.com \
--cc=linux-trace-devel@vger.kernel.org \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).