From: Stephane Eranian <eranian@google.com>
To: linux-kernel@vger.kernel.org
Cc: peterz@infradead.org, mingo@elte.hu, ak@linux.intel.com,
jmario@redhat.com, dzickus@redhat.com, jolsa@redhat.com,
acme@redhat.com
Subject: [PATCH v2 2/2] perf/x86: load latency event supports all PEBS counters
Date: Fri, 27 Jun 2014 15:48:03 +0200 [thread overview]
Message-ID: <1403876883-3059-3-git-send-email-eranian@google.com> (raw)
In-Reply-To: <1403876883-3059-1-git-send-email-eranian@google.com>
This patch relaxes the event constraint for the Load
Latency PEBS event on SNB/IVB/HSW. It was limited to
counter 3 only for artificial reasons, i.e., to make
scheduling it easier. This event uses an extra MSR
which has to be shared among all events of a PMU.
In Linux, there is a sophisticated infratstructure
to handle shared regs, and we don't need to constrain
the event to one counter.
The advantage of this patch is that it makes it
possible to combine load latency and precise store
events without multiplexing.
Signed-off-by: Stephane Eranian <eranian@google.com>
---
arch/x86/kernel/cpu/perf_event_intel_ds.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/arch/x86/kernel/cpu/perf_event_intel_ds.c b/arch/x86/kernel/cpu/perf_event_intel_ds.c
index fdadec0..9dbfc9b 100644
--- a/arch/x86/kernel/cpu/perf_event_intel_ds.c
+++ b/arch/x86/kernel/cpu/perf_event_intel_ds.c
@@ -579,7 +579,7 @@ struct event_constraint intel_westmere_pebs_event_constraints[] = {
struct event_constraint intel_snb_pebs_event_constraints[] = {
INTEL_UEVENT_CONSTRAINT(0x01c0, 0x2), /* INST_RETIRED.PRECDIST */
- INTEL_PLD_CONSTRAINT(0x01cd, 0x8), /* MEM_TRANS_RETIRED.LAT_ABOVE_THR */
+ INTEL_PLD_CONSTRAINT(0x01cd, 0xf), /* MEM_TRANS_RETIRED.LAT_ABOVE_THR */
INTEL_PST_CONSTRAINT(0x02cd, 0x8), /* MEM_TRANS_RETIRED.PRECISE_STORES */
INTEL_PEBS_CONSTRAINT(0xf), /* catch all PEBS */
EVENT_CONSTRAINT_END
@@ -587,7 +587,7 @@ struct event_constraint intel_snb_pebs_event_constraints[] = {
struct event_constraint intel_ivb_pebs_event_constraints[] = {
INTEL_UEVENT_CONSTRAINT(0x01c0, 0x2), /* INST_RETIRED.PRECDIST */
- INTEL_PLD_CONSTRAINT(0x01cd, 0x8), /* MEM_TRANS_RETIRED.LAT_ABOVE_THR */
+ INTEL_PLD_CONSTRAINT(0x01cd, 0xf), /* MEM_TRANS_RETIRED.LAT_ABOVE_THR */
INTEL_PST_CONSTRAINT(0x02cd, 0x8), /* MEM_TRANS_RETIRED.PRECISE_STORES */
INTEL_PEBS_CONSTRAINT(0xf), /* catch all PEBS */
EVENT_CONSTRAINT_END
@@ -596,7 +596,7 @@ struct event_constraint intel_ivb_pebs_event_constraints[] = {
struct event_constraint intel_hsw_pebs_event_constraints[] = {
INTEL_UEVENT_CONSTRAINT(0x01c0, 0x2), /* INST_RETIRED.PRECDIST */
INTEL_PST_HSW_CONSTRAINT(0x01c2, 0xf), /* UOPS_RETIRED.ALL */
- INTEL_PLD_CONSTRAINT(0x01cd, 0x8), /* MEM_TRANS_RETIRED.* */
+ INTEL_PLD_CONSTRAINT(0x01cd, 0xf), /* MEM_TRANS_RETIRED.* */
INTEL_PST_HSW_CONSTRAINT(0x82d0, 0xf), /* MEM_UOPS_RETIRED.ALL_STORES */
INTEL_PEBS_CONSTRAINT(0xf), /* catch all PEBS */
EVENT_CONSTRAINT_END
--
1.7.9.5
prev parent reply other threads:[~2014-06-27 13:48 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-27 13:48 [PATCH v2 0/2] perf/x86: simplify PEBS constraints Stephane Eranian
2014-06-27 13:48 ` [PATCH v2 1/2] " Stephane Eranian
2014-06-27 15:37 ` Andi Kleen
2014-07-01 17:04 ` Stephane Eranian
2014-07-01 18:20 ` Andi Kleen
2014-06-27 13:48 ` Stephane Eranian [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=1403876883-3059-3-git-send-email-eranian@google.com \
--to=eranian@google.com \
--cc=acme@redhat.com \
--cc=ak@linux.intel.com \
--cc=dzickus@redhat.com \
--cc=jmario@redhat.com \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=peterz@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
Powered by JetHome