All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] perf events, x86: Add SandyBridge stalled-cycles-frontend/backend events
@ 2011-05-06  7:14 Lin Ming
  2011-05-06  7:38 ` Ingo Molnar
  2011-05-06  7:40 ` [tip:perf/core] perf events, x86: Add SandyBridge stalled-cycles-frontend/backend events tip-bot for Lin Ming
  0 siblings, 2 replies; 10+ messages in thread
From: Lin Ming @ 2011-05-06  7:14 UTC (permalink / raw)
  To: Peter Zijlstra, Ingo Molnar; +Cc: linux-kernel

Extend the Intel SandyBridge PMU driver with definitions
for generic front-end and back-end stall events.

( As commit 3011203 says, these are only approximations. )

Signed-off-by: Lin Ming <ming.m.lin@intel.com>
---
 arch/x86/kernel/cpu/perf_event_intel.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/arch/x86/kernel/cpu/perf_event_intel.c b/arch/x86/kernel/cpu/perf_event_intel.c
index c1ec7a5..61cbf48 100644
--- a/arch/x86/kernel/cpu/perf_event_intel.c
+++ b/arch/x86/kernel/cpu/perf_event_intel.c
@@ -1485,6 +1485,12 @@ static __init int intel_pmu_init(void)
 
 		x86_pmu.event_constraints = intel_snb_event_constraints;
 		x86_pmu.pebs_constraints = intel_snb_pebs_events;
+
+		/* UOPS_ISSUED.ANY,c=1,i=1 to count stall cycles */
+		intel_perfmon_event_map[PERF_COUNT_HW_STALLED_CYCLES_FRONTEND] = 0x180010e;
+		/* UOPS_DISPATCHED.THREAD,c=1,i=1 to count stall cycles*/
+		intel_perfmon_event_map[PERF_COUNT_HW_STALLED_CYCLES_BACKEND] = 0x18001b1;
+
 		pr_cont("SandyBridge events, ");
 		break;
 
-- 
1.7.4.4


^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2011-05-09  8:43 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-05-06  7:14 [PATCH] perf events, x86: Add SandyBridge stalled-cycles-frontend/backend events Lin Ming
2011-05-06  7:38 ` Ingo Molnar
2011-05-06  7:43   ` Lin Ming
2011-05-06 13:44     ` Lin Ming
2011-05-06  9:19   ` [PATCH] perf events, x86: Implement Sandybridge last-level cache events Ingo Molnar
2011-05-06 13:47     ` Lin Ming
2011-05-09  8:45       ` Lin Ming
2011-05-06  7:40 ` [tip:perf/core] perf events, x86: Add SandyBridge stalled-cycles-frontend/backend events tip-bot for Lin Ming
2011-05-06 15:51   ` Steven Rostedt
2011-05-06 19:08     ` Ingo Molnar

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.