public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Andy Lutomirski <luto@kernel.org>
Cc: Len Brown <len.brown@intel.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Paul Mackerras <paulus@samba.org>, Ingo Molnar <mingo@redhat.com>,
	Arnaldo Carvalho de Melo <acme@kernel.org>
Subject: Re: [RFC] x86, perf: Add an aperfmperf driver
Date: Wed, 29 Apr 2015 11:14:50 +0200	[thread overview]
Message-ID: <20150429091450.GQ5029@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <2c37309d20afadf88ad4a82cf0ce02b9152801e2.1430256154.git.luto@kernel.org>

On Tue, Apr 28, 2015 at 02:25:37PM -0700, Andy Lutomirski wrote:

> +static struct pmu pmu_aperfmperf = {
> +        .task_ctx_nr    = perf_invalid_context,

You could actually have made that perf_sw_context, because its
impossible to fail to add() this event. That will make it possible to
attach it to tasks and you can measure per task a/m-perf.

> +	.attr_groups	= attr_groups,
> +        .event_init     = aperfmperf_event_init,
> +        .add            = aperfmperf_event_add,
> +        .del            = aperfmperf_event_stop_or_del,
> +        .start          = aperfmperf_event_start,
> +        .stop           = aperfmperf_event_stop_or_del,
> +        .read           = aperfmperf_event_update,
> +};

  parent reply	other threads:[~2015-04-29  9:15 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-28 21:25 [RFC] x86, perf: Add an aperfmperf driver Andy Lutomirski
2015-04-28 22:29 ` Brown, Len
2015-04-28 22:43   ` Andy Lutomirski
2015-04-29  9:13     ` Peter Zijlstra
2015-04-29  9:09 ` Peter Zijlstra
2015-04-29 18:50   ` Andy Lutomirski
2015-04-30  1:17     ` Andy Lutomirski
2015-04-30  8:51       ` Peter Zijlstra
2015-04-30 22:09         ` Andy Lutomirski
2015-04-29  9:14 ` Peter Zijlstra [this message]
2015-05-11  9:48 ` Ingo Molnar

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=20150429091450.GQ5029@twins.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=acme@kernel.org \
    --cc=len.brown@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luto@kernel.org \
    --cc=mingo@redhat.com \
    --cc=paulus@samba.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