linux-perf-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Namhyung Kim <namhyung@kernel.org>
To: Leo Yan <leo.yan@linaro.org>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>,
	Jiri Olsa <jolsa@kernel.org>, Ingo Molnar <mingo@kernel.org>,
	Peter Zijlstra <peterz@infradead.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Ian Rogers <irogers@google.com>,
	linux-perf-users <linux-perf-users@vger.kernel.org>,
	John Garry <john.garry@huawei.com>, Will Deacon <will@kernel.org>,
	James Clark <james.clark@arm.com>,
	Mike Leach <mike.leach@linaro.org>,
	German Gomez <german.gomez@arm.com>
Subject: Re: [PATCH v2] perf test: Add ARM SPE system wide test
Date: Thu, 23 Jun 2022 23:22:16 -0700	[thread overview]
Message-ID: <CAM9d7ci8pLo=dKFgF8O8610eHTx532d+1TKTf18ibPMtdZp5Lg@mail.gmail.com> (raw)
In-Reply-To: <20220617074517.GB45710@leoy-ThinkPad-X240s>

Hi Leo,

On Fri, Jun 17, 2022 at 12:45 AM Leo Yan <leo.yan@linaro.org> wrote:
>
> On Fri, Jun 17, 2022 at 03:38:40PM +0800, Leo Yan wrote:
> > Hi Namhyung,
> >
> > On Thu, Jun 16, 2022 at 04:05:46PM -0700, Namhyung Kim wrote:
> >
> > [...]
> >
> > > +arm_spe_system_wide_test() {
> > > +   echo "Recording trace with system-wide mode $perfdata"
> > > +   perf record -o ${perfdata} -e arm_spe// -a \
> > > +           -- dd if=/dev/zero of=/dev/null count=100000 > /dev/null 2>&1
> > > +
> > > +   if [ $? != 0 ]; then
> > > +           arm_spe_report "SPE system-wide testing" 2
> > > +           return
> > > +   fi
> >
> > I am awared the root permission issue after I saw German's suggestion.
> >
> > If the snapshot test is passed, no matter the system wide test is passed
> > or not, we will always return 0 for 'passed' result.  But we might miss
> > to capture the system-wide testing failure.
> >
> > How about use 'dummy' event to verіfy the root permission?
> > (actually I referred to intel-pt test):
> >
> >         perf record -o ${perfdata} -B -N --no-bpf-event -e dummy:u -a true 2>&1 >/dev/null
> >         if [ $? != 0 ]; then
> >               arm_spe_report "SPE system-wide testing" 2
> >               return
> >         fi
> >
> >         perf record -o ${perfdata} -e arm_spe// -a \
> >                   -- dd if=/dev/zero of=/dev/null count=100000 > /dev/null 2>&1

Ok, will add the change.

Thanks,
Namhyung

      reply	other threads:[~2022-06-24  6:22 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-16 23:05 [PATCH v2] perf test: Add ARM SPE system wide test Namhyung Kim
2022-06-17  7:38 ` Leo Yan
2022-06-17  7:45   ` Leo Yan
2022-06-24  6:22     ` Namhyung Kim [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='CAM9d7ci8pLo=dKFgF8O8610eHTx532d+1TKTf18ibPMtdZp5Lg@mail.gmail.com' \
    --to=namhyung@kernel.org \
    --cc=acme@kernel.org \
    --cc=german.gomez@arm.com \
    --cc=irogers@google.com \
    --cc=james.clark@arm.com \
    --cc=john.garry@huawei.com \
    --cc=jolsa@kernel.org \
    --cc=leo.yan@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mike.leach@linaro.org \
    --cc=mingo@kernel.org \
    --cc=peterz@infradead.org \
    --cc=will@kernel.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).