All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Kim Phillips <kim.phillips@amd.com>
Cc: Stephane Eranian <eranian@google.com>,
	Ingo Molnar <mingo@kernel.org>, Ingo Molnar <mingo@redhat.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Borislav Petkov <bp@alien8.de>,
	Alexander Shishkin <alexander.shishkin@linux.intel.com>,
	Arnaldo Carvalho de Melo <acme@kernel.org>,
	"H. Peter Anvin" <hpa@zytor.com>, Jiri Olsa <jolsa@redhat.com>,
	Mark Rutland <mark.rutland@arm.com>,
	Michael Petlan <mpetlan@redhat.com>,
	Namhyung Kim <namhyung@kernel.org>,
	LKML <linux-kernel@vger.kernel.org>, x86 <x86@kernel.org>
Subject: Re: [PATCH 1/3 v2] perf/amd/uncore: Prepare L3 thread mask code for Family 19h support
Date: Wed, 18 Mar 2020 21:42:57 +0100	[thread overview]
Message-ID: <20200318204257.GL20730@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <2581de5a-969b-93c7-0565-2eef51717900@amd.com>

On Wed, Mar 18, 2020 at 09:46:41AM -0500, Kim Phillips wrote:

> > But this does not work with the cpumask programmed for the amd_l3 PMU. This mask
> > shows, as it should, one CPU/CCX. So that means that when I do:
> > 
> > $ perf stat -a amd_l3/event=llc_event/
> > 
> > This only collects on the CPUs listed in the cpumask: 0,4,8,12 ....
> > That means that L3 events generated by the other CPUs on the CCX are
> > not monitored.
> > I can easily see the problem by pinning a memory bound program to
> > CPU64, for instance.
> 
> Right, the higher level code calls the driver with a single cpu==0
> call if the perf tool is invoked with a simple -a style system-wide.
> If the tool is invoked with supplemental switches to -a, like -C 0-255,
> and -A, the driver gets called multiple times with all the unique cpu
> values.  The latter is the expected invocation style when measuring
> a benchmark pinned on a subset of cpus, i.e., when evaluating
> the driver, and is the more deterministic behaviour for the driver
> to have, given it cannot tell the difference otherwise.

That seems to suggest it is all horribly broken.

  reply	other threads:[~2020-03-18 20:43 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-13 23:10 [PATCH 1/3 v2] perf/amd/uncore: Prepare L3 thread mask code for Family 19h support Kim Phillips
2020-03-13 23:10 ` [PATCH 2/3 v2] perf/amd/uncore: Make L3 thread mask code more readable Kim Phillips
2020-03-17 12:07   ` [tip: perf/core] " tip-bot2 for Kim Phillips
2020-03-13 23:10 ` [PATCH 3/3 v2] perf/amd/uncore: Add support for Family 19h L3 PMU Kim Phillips
2020-03-17 12:07   ` [tip: perf/core] " tip-bot2 for Kim Phillips
2020-03-17 12:07 ` [tip: perf/core] perf/amd/uncore: Prepare L3 thread mask code for Family 19h tip-bot2 for Kim Phillips
2020-03-18  2:09 ` [PATCH 1/3 v2] perf/amd/uncore: Prepare L3 thread mask code for Family 19h support Stephane Eranian
2020-03-18 14:46   ` Kim Phillips
2020-03-18 20:42     ` Peter Zijlstra [this message]
2020-03-18 21:26       ` Stephane Eranian
2020-03-23 20:50         ` Kim Phillips

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=20200318204257.GL20730@hirez.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=acme@kernel.org \
    --cc=alexander.shishkin@linux.intel.com \
    --cc=bp@alien8.de \
    --cc=eranian@google.com \
    --cc=hpa@zytor.com \
    --cc=jolsa@redhat.com \
    --cc=kim.phillips@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mingo@kernel.org \
    --cc=mingo@redhat.com \
    --cc=mpetlan@redhat.com \
    --cc=namhyung@kernel.org \
    --cc=tglx@linutronix.de \
    --cc=x86@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.