From: David Marchand <david.marchand@redhat.com>
To: Sunil Kumar Kori <skori@marvell.com>, Jerin Jacob <jerinj@marvell.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
"fengchengwen@huawei.com" <fengchengwen@huawei.com>,
Kevin Laatz <kevin.laatz@intel.com>,
Bruce Richardson <bruce.richardson@intel.com>,
Tyler Retzlaff <roretzla@linux.microsoft.com>
Subject: Re: [EXTERNAL] [PATCH v3 4/6] trace: support dumping binary inside a struct
Date: Tue, 18 Feb 2025 15:28:07 +0100 [thread overview]
Message-ID: <CAJFAV8zLcY=XcyKHhrknedhbwUZ8Hs2_XzxpkmTmuVj-Z4XF4Q@mail.gmail.com> (raw)
In-Reply-To: <CO6PR18MB386067633D5066F40955C023B4FC2@CO6PR18MB3860.namprd18.prod.outlook.com>
On Wed, Feb 12, 2025 at 6:14 AM Sunil Kumar Kori <skori@marvell.com> wrote:
>
> > On Tue, Feb 11, 2025 at 9:53 AM Sunil Kumar Kori <skori@marvell.com>
> > wrote:
> > >
> > > > diff --git a/lib/eal/common/eal_common_trace_ctf.c
> > > > b/lib/eal/common/eal_common_trace_ctf.c
> > > > index 6bc8bb9036..d9b307e076 100644
> > > > --- a/lib/eal/common/eal_common_trace_ctf.c
> > > > +++ b/lib/eal/common/eal_common_trace_ctf.c
> > > > @@ -378,6 +378,9 @@ char *trace_metadata_fixup_field(const char
> > *field)
> > > > "->",
> > > > "*",
> > > > " ",
> > > > + "&",
> > > > + "(",
> > > > + ")",
> > > Adding brackets makes token names a bit complex. Same name is used in
> > > metadata file to dump the traces to the user. With this complex name,
> > > user might not understand the purpose of that information.
> > >
> > > For example, _conf_src_port_pcie_sizeof_uint64_t_ is created in
> > > metafile and same will be dumped. But with this User might not get that
> > which information is provided.
> >
> > In practice, as there is no other documentation for a trace point arguments, a
> > user needs to read the trace point definitions.
> > So it seems trivial to me to link a variable name in the trace point emitter, and
> > the metadata in the trace files.
> >
> > >
> > > This is the reason; we followed the existing naming convention which is user
> > friendly.
> >
> > User friendly? I don't see how this is different with '.' and '->'.
> In general, structure fields are given a proper name to represent the purpose.
> When we use it directly in trace point using '.' or '->' then it remains a meaningful name.
> Adding more tokens in name, is making them complex and deviating from there meaning.
>
> I am not saying that the mentioned support should not be there. I am just trying to convey
> that If it is possible to make meaningful names, then that will be more helpful.
Hard to preserve such information given the limitations of the C
parser (which seems to apply to the CTF format).
I still think that interpretation of the metadata in the traces
require looking at the source code, which means that the "readability"
objection is weak.
Jerin, opinion please.
--
David Marchand
next prev parent reply other threads:[~2025-02-18 14:28 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-24 16:14 [PATCH 1/2] trace: support expression for blob length David Marchand
2025-01-24 16:14 ` [PATCH 2/2] dmadev: avoid copies in tracepoints David Marchand
2025-01-27 8:25 ` [EXTERNAL] [PATCH 1/2] trace: support expression for blob length Jerin Jacob
2025-01-30 14:58 ` [PATCH v2 1/3] " David Marchand
2025-01-30 14:58 ` [PATCH v2 2/3] dmadev: avoid copies in tracepoints David Marchand
2025-01-30 14:58 ` [PATCH v2 3/3] trace: fix undefined behavior in register David Marchand
2025-01-30 19:10 ` Stephen Hemminger
2025-01-30 21:06 ` David Marchand
2025-02-07 8:49 ` David Marchand
2025-02-07 11:39 ` [EXTERNAL] " Sunil Kumar Kori
2025-02-10 9:02 ` Sunil Kumar Kori
2025-02-10 9:36 ` David Marchand
2025-02-10 13:37 ` [EXTERNAL] " Jerin Jacob
2025-02-10 14:04 ` David Marchand
2025-02-10 13:38 ` [EXTERNAL] [PATCH v2 1/3] trace: support expression for blob length Jerin Jacob
2025-02-10 17:44 ` [PATCH v3 0/6] Trace point framework enhancement for dmadev David Marchand
2025-02-10 17:44 ` [PATCH v3 1/6] ci: check traces validity David Marchand
2025-02-10 17:44 ` [PATCH v3 2/6] trace: support dereferencing arguments David Marchand
2025-02-11 8:44 ` [EXTERNAL] " Sunil Kumar Kori
2025-02-11 9:53 ` David Marchand
2025-02-12 5:08 ` Sunil Kumar Kori
2025-02-10 17:44 ` [PATCH v3 3/6] trace: support expression for blob length David Marchand
2025-02-10 17:44 ` [PATCH v3 4/6] trace: support dumping binary inside a struct David Marchand
2025-02-11 8:52 ` [EXTERNAL] " Sunil Kumar Kori
2025-02-11 9:54 ` David Marchand
2025-02-12 5:14 ` Sunil Kumar Kori
2025-02-18 14:28 ` David Marchand [this message]
2025-02-19 11:17 ` Jerin Jacob
2025-02-10 17:44 ` [PATCH v3 5/6] dmadev: avoid copies in tracepoints David Marchand
2025-02-10 17:44 ` [PATCH v3 6/6] trace: fix undefined behavior in register David Marchand
2025-02-11 8:41 ` [EXTERNAL] [PATCH v3 0/6] Trace point framework enhancement for dmadev Sunil Kumar Kori
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='CAJFAV8zLcY=XcyKHhrknedhbwUZ8Hs2_XzxpkmTmuVj-Z4XF4Q@mail.gmail.com' \
--to=david.marchand@redhat.com \
--cc=bruce.richardson@intel.com \
--cc=dev@dpdk.org \
--cc=fengchengwen@huawei.com \
--cc=jerinj@marvell.com \
--cc=kevin.laatz@intel.com \
--cc=roretzla@linux.microsoft.com \
--cc=skori@marvell.com \
/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).