From: Dave Chinner <david@fromorbit.com>
To: Matthew Wilcox <willy@infradead.org>
Cc: Hongbo Li <lihongbo22@huawei.com>,
muchun.song@linux.dev, rostedt@goodmis.org, mhiramat@kernel.org,
mathieu.desnoyers@efficios.com, linux-mm@kvack.org,
linux-trace-kernel@vger.kernel.org,
linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH v2 1/2] hugetlbfs: support tracepoint
Date: Thu, 4 Jul 2024 22:56:29 +1000 [thread overview]
Message-ID: <Zoab/VXoPkUna7L2@dread.disaster.area> (raw)
In-Reply-To: <ZoYY-sfj5jvs8UpQ@casper.infradead.org>
On Thu, Jul 04, 2024 at 04:37:30AM +0100, Matthew Wilcox wrote:
> On Thu, Jul 04, 2024 at 11:07:03AM +0800, Hongbo Li wrote:
> > + TP_printk("dev = (%d,%d), ino = %lu, dir = %lu, mode = 0%o",
> > + MAJOR(__entry->dev), MINOR(__entry->dev),
> > + (unsigned long) __entry->ino,
> > + (unsigned long) __entry->dir, __entry->mode)
>
> erofs and f2fs are the only two places that print devices like this.
>
> "dev=%d:%d inode=%lx"
"dev %d:%d inode %lx"
i.e. every token in the output should be space separated, and no
commas between values.
Any other format makes it difficult for post processing tracepoint
output with sed, grep, awk, python, etc. Every token then has to be
split into name and value parts, and then the value has to have the
comma stripped from it.
Having to do this is additional work when writing use-once scripts
that get thrown away when the tracepoint output analysis is done
is painful, and it's completely unnecessary if the tracepoint output
is completely space separated from the start.
-Dave.
--
Dave Chinner
david@fromorbit.com
next prev parent reply other threads:[~2024-07-04 12:56 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-04 3:07 [PATCH v2 0/2] Introduce tracepoint for hugetlbfs Hongbo Li
2024-07-04 3:07 ` [PATCH v2 1/2] hugetlbfs: support tracepoint Hongbo Li
2024-07-04 3:37 ` Matthew Wilcox
2024-07-04 6:40 ` Hongbo Li
2024-07-04 12:56 ` Dave Chinner [this message]
2024-07-04 14:13 ` Steven Rostedt
2024-07-04 23:34 ` Dave Chinner
2024-07-05 6:24 ` Hongbo Li
2024-07-04 3:07 ` [PATCH v2 2/2] hugetlbfs: use tracepoints in hugetlbfs functions Hongbo Li
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=Zoab/VXoPkUna7L2@dread.disaster.area \
--to=david@fromorbit.com \
--cc=lihongbo22@huawei.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-trace-kernel@vger.kernel.org \
--cc=mathieu.desnoyers@efficios.com \
--cc=mhiramat@kernel.org \
--cc=muchun.song@linux.dev \
--cc=rostedt@goodmis.org \
--cc=willy@infradead.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