Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754521AbbGXV0d (ORCPT ); Fri, 24 Jul 2015 17:26:33 -0400 Received: from mail-wi0-f175.google.com ([209.85.212.175]:37045 "EHLO mail-wi0-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752785AbbGXV0c (ORCPT ); Fri, 24 Jul 2015 17:26:32 -0400 MIME-Version: 1.0 In-Reply-To: <37D7C6CF3E00A74B8858931C1DB2F077018CC567@SHSMSX103.ccr.corp.intel.com> References: <1437741564-8717-1-git-send-email-kan.liang@intel.com> <37D7C6CF3E00A74B8858931C1DB2F077018CC567@SHSMSX103.ccr.corp.intel.com> Date: Fri, 24 Jul 2015 14:26:29 -0700 Message-ID: Subject: Re: [PATCH 1/1] perf/x86: Add Intel power cstate PMUs support From: Stephane Eranian To: "Liang, Kan" Cc: Peter Zijlstra , "mingo@redhat.com" , Arnaldo Carvalho de Melo , "ak@linux.intel.com" , LKML Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2503 Lines: 50 On Fri, Jul 24, 2015 at 1:57 PM, Liang, Kan wrote: >> > + * MSR_PKG_C6_RESIDENCY: Package C6 Residency Counter. >> > + * perf code: 0x06 >> > + * Available model: NHM,WSM,SNB,IVB,HSW,BDW >> > + * Scope: Package (physical package) >> > + * MSR_PKG_C7_RESIDENCY: Package C7 Residency Counter. >> > + * perf code: 0x07 >> > + * Available model: NHM,WSM,SNB,IVB,HSW,BDW >> > + * Scope: Package (physical package) >> > + * MSR_PKG_C8_RESIDENCY: Package C8 Residency Counter. >> > + * perf code: 0x08 >> > + * Available model: HSW ULT only >> > + * Scope: Package (physical package) >> > + * MSR_PKG_C9_RESIDENCY: Package C9 Residency Counter. >> > + * perf code: 0x09 >> > + * Available model: HSW ULT only >> > + * Scope: Package (physical package) >> > + * MSR_PKG_C10_RESIDENCY: Package C10 Residency Counter. >> > + * perf code: 0x0a >> > + * Available model: HSW ULT only >> > + * Scope: Package (physical package) >> > + * MSR_SLM_PKG_C6_RESIDENCY: Package C6 Residency Counter for >> SLM. >> > + * perf code: 0x0b >> > + * Available model: SLM,AMT >> > + * Scope: Package (physical package) >> > + * >> > + */ >> > + >> Why would the user (and the tools) have to change the event code to >> measure, let's say C6 residency, between SLM (0xb) and and BDW (0x6)? >> Are they not measuring the same thing? >> > > Yes, they are measuring the same thing, but with different MSR. > I will make their event code consistent and special handle PKG_C6 > in event_init in next version. > The user should not be concerned with the MSR mapping. The user should only see the event name and understand what it measures. The kernel should take care of mapping the event to the correct MSR as per perf_events design. > > Thanks, > Kan -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/