From: Michael Petlan <mpetlan@redhat.com>
To: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>,
Arnaldo de Melo <acme@redhat.com>,
Thomas-Mich Richter <tmricht@linux.vnet.ibm.com>,
linux-perf-users@vger.kernel.org, Jiri Olsa <jolsa@redhat.com>,
kernel-team@lge.com
Subject: Re: [PATCH] perf test shell: Fix check open filename arg using 'perf trace'
Date: Wed, 6 Dec 2017 00:18:59 +0100 (CET) [thread overview]
Message-ID: <alpine.LRH.2.20.1712060007430.9416@Diego> (raw)
In-Reply-To: <20171201151628.GB3298@kernel.org>
On Fri, 1 Dec 2017, Arnaldo Carvalho de Melo wrote:
> Em Fri, Dec 01, 2017 at 11:33:14AM +0900, Namhyung Kim escreveu:
[...]
>
> > > What differs from x86 to others is that x86 uses syscalltbl, not requiring
> > > audit-libs to map syscall numbers to names, so perhaps it is something in there...
>
> > If it only needs to consider open or openat, why not specifying the
> > both directly?
>
> > # perf trace -e open -e openat touch /etc/passwd
>
> Same effect, works with other perf trace versions, but one suggestion to
> make it shorter:
>
> perf trace -e open,openat touch /etc/passwd
>
> Does the same thing :-)
Well, do I understand it correctly, that we prefer the "-e open,openat" over
the "-e 'open*'" because there are issues with the globbing feature on some
architectures?
I see a disadvantage of "-e open,openat" concept in that it does not work
in case any of them is unavailable. So in case some kernel does not contain
e.g. open in favor of openat, perf-trace fails to trace them. This can be
easily simulated like `perf trace -e open,openit`:
event syntax error: 'openit'
\___ Cannot find PMU `openit'. Missing kernel support?
Run 'perf list' for a list of valid events
Since it is possible that open is not even supported, having both of them
there is fragile. The "-e 'open*'" approach should expand only to supported
syscalls.
The '' are necessary there, since just open* can expand to some filename.
.....
I also see problems with globbing on my aarch64 with 4.14, so that makes
the "-e 'open*'" fragile too...
Ideas?
>
> Michael, can you please take that into account and resubmit the patch?
>
> - Arnaldo
> --
> To unsubscribe from this list: send the line "unsubscribe linux-perf-users" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
next prev parent reply other threads:[~2017-12-05 23:19 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-29 17:27 [PATCH] perf test shell: Fix check open filename arg using 'perf trace' Michael Petlan
2017-11-30 10:28 ` Thomas-Mich Richter
2017-11-30 15:56 ` Arnaldo de Melo
2017-11-30 15:59 ` Arnaldo de Melo
2017-12-05 15:39 ` Hendrik Brueckner
2017-12-06 16:34 ` Arnaldo Carvalho de Melo
2017-12-07 7:39 ` Hendrik Brueckner
2017-12-01 2:33 ` Namhyung Kim
2017-12-01 15:16 ` Arnaldo Carvalho de Melo
2017-12-02 23:21 ` Michael Petlan
2017-12-05 23:18 ` Michael Petlan [this message]
2017-12-06 14:28 ` Arnaldo de Melo
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=alpine.LRH.2.20.1712060007430.9416@Diego \
--to=mpetlan@redhat.com \
--cc=acme@kernel.org \
--cc=acme@redhat.com \
--cc=jolsa@redhat.com \
--cc=kernel-team@lge.com \
--cc=linux-perf-users@vger.kernel.org \
--cc=namhyung@kernel.org \
--cc=tmricht@linux.vnet.ibm.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).