Re: [PATCH v13 04/11] perf/probe: Ignore comment lines in dynamic_events/kprobe_events file
From: Namhyung Kim
Date: Mon Jun 29 2026 - 20:33:55 EST
Hi Masami,
On Tue, Jun 30, 2026 at 07:32:11AM +0900, Masami Hiramatsu wrote:
> Hi Arnaldo, Namhyung,
>
> I forgot to CC this. Can I pick this patch via linux-trace tree,
> or would you pick this?
> This is a part of typecast series [1] only for debugging.
Thanks for letting me know.
I think it's better to route this through the perf tree as we're seeing
a lot of cleanups all around the code base. Having this together would
reduce chances of future conflicts. Does that sound ok to you?
Thanks,
Namhyung
>
> [1] https://lore.kernel.org/all/178271361825.1176915.16095297120719039761.stgit@devnote2/
>
> Thanks,
>
> On Mon, 29 Jun 2026 15:13:38 +0900
> "Masami Hiramatsu (Google)" <mhiramat@xxxxxxxxxx> wrote:
>
> > From: Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>
> >
> > Since dynamic_events/kprobe_events files show the fetcharg debug
> > information as comment lines, its reader needs to ignore it.
> >
> > Signed-off-by: Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>
> > ---
> > tools/perf/util/probe-file.c | 2 ++
> > 1 file changed, 2 insertions(+)
> >
> > diff --git a/tools/perf/util/probe-file.c b/tools/perf/util/probe-file.c
> > index 4032572cbf55..4d12693a83b3 100644
> > --- a/tools/perf/util/probe-file.c
> > +++ b/tools/perf/util/probe-file.c
> > @@ -197,6 +197,8 @@ struct strlist *probe_file__get_rawlist(int fd)
> > idx = strlen(p) - 1;
> > if (p[idx] == '\n')
> > p[idx] = '\0';
> > + if (buf[0] == '#')
> > + continue;
> > ret = strlist__add(sl, buf);
> > if (ret < 0) {
> > pr_debug("strlist__add failed (%d)\n", ret);
> >
>
>
> --
> Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>