All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <a.p.zijlstra@chello.nl>
To: Zhang Rui <rui.zhang@intel.com>
Cc: Matt Fleming <matt@console-pimps.org>,
	"Lin, Ming M" <ming.m.lin@intel.com>,
	Corey Ashford <cjashfor@linux.vnet.ibm.com>,
	LKML <linux-kernel@vger.kernel.org>,
	Stephane Eranian <eranian@google.com>,
	"acme@redhat.com" <acme@redhat.com>,
	linux-pm <linux-pm@lists.linux-foundation.org>,
	"mingo@elte.hu" <mingo@elte.hu>
Subject: Re: [PATCH 2/3] introduce intel_rapl driver
Date: Fri, 27 May 2011 21:56:35 +0200	[thread overview]
Message-ID: <1306526195.2497.475.camel__27037.985440302$1306538753$gmane$org@laptop> (raw)
In-Reply-To: <1306484810.16581.375.camel@rui>

On Fri, 2011-05-27 at 16:26 +0800, Zhang Rui wrote:
> 
> > Currently there isn't a way to expose the events in sysfs, but we do
> > want that, its mostly a matter of getting all involved parties to agree
> > on a format and implementing it.
> > 
> I talked with Lin Ming just now, and he said that it should work in this
> way:
> First, only one pmu for RAPL interfaces, with four different kinds of
> events, pkg/core/uncore/dram,
> and the sysfs I/F is:
> /sys/bus/event_source/devices/rapl/---|---type
>                                       |---pkg
>                                       |---core
>                                       |---uncore
>                                       |---dram

Actually something like:

 /sys/bus/.../rapl/ -- | -- type
                       | -- events -- | -- pkg
                                      | -- core
                                      | ...

was one of the latest proposals, but then someone (can't remember who)
offered the opinion that having sub-groups of event might also be
wanted.

Furthermore a 'format' file was proposed which ought to contain a
description of how to compose a ::config value, but we never got around
to discussing a valid/useful syntax that could express all existing
cases (let alone be future proof).

> to use it, users can issue something like:
> perf stat -P rapl -e pkg/core/uncore/dram foo
> so that event->attr.type equals rapl_pmu.type and event->attr.config
> equals one of the rapl_domain_id.

Right, something like that, or simply something like -e rapl:pkg, which
again reminds me that people were working on a full EBNF syntax for the
-e argument.

> This sounds good. I can rewrite the code to work in this way, but it
> doesn't work for now, until both sysfs I/F and perf tool being ready,
> right? 

Right, so the only thing missing is the event bits (and some userspace
bits to use it all). The hardest part of it is getting those definitions
sorted, writing the patches shouldn't be too hard.

  parent reply	other threads:[~2011-05-27 19:56 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-26  8:34 [PATCH 2/3] introduce intel_rapl driver Zhang Rui
2011-05-26  9:43 ` Peter Zijlstra
2011-05-26  9:43 ` Peter Zijlstra
2011-05-26 10:21   ` Peter Zijlstra
2011-05-26 10:21   ` Peter Zijlstra
2011-05-26 10:55   ` Matt Fleming
2011-06-02  8:04     ` Matt Fleming
2011-06-02  8:04       ` Matt Fleming
2011-05-26 10:55   ` Matt Fleming
2011-05-27  8:26   ` Zhang Rui
2011-05-27  8:26   ` Zhang Rui
2011-05-27 19:56     ` Peter Zijlstra
2011-05-27 19:56     ` Peter Zijlstra
2011-05-27 19:56     ` Peter Zijlstra
2011-05-30  3:11       ` Zhang Rui
2011-05-30  3:11       ` Zhang Rui
2011-05-27 19:56     ` Peter Zijlstra [this message]
2011-05-26 15:48 ` Randy Dunlap
2011-05-30  2:40   ` Zhang Rui
2011-05-30  2:40   ` Zhang Rui
2011-05-26 15:48 ` Randy Dunlap
2011-05-28 10:17 ` Greg KH
2011-05-30  7:04   ` Zhang Rui
2011-05-30  7:04   ` Zhang Rui
2011-05-28 10:17 ` Greg KH
2011-05-26  8:34 Zhang Rui

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='1306526195.2497.475.camel__27037.985440302$1306538753$gmane$org@laptop' \
    --to=a.p.zijlstra@chello.nl \
    --cc=acme@redhat.com \
    --cc=cjashfor@linux.vnet.ibm.com \
    --cc=eranian@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@lists.linux-foundation.org \
    --cc=matt@console-pimps.org \
    --cc=ming.m.lin@intel.com \
    --cc=mingo@elte.hu \
    --cc=rui.zhang@intel.com \
    /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.