mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Andi Kleen <andi@firstfloor.org>
Cc: linux-kernel@vger.kernel.org, mingo@kernel.org,
	Andi Kleen <ak@linux.intel.com>
Subject: Re: [PATCH 2/2] x86, perf: Allow zero PEBS status with only single active event
Date: Thu, 3 Dec 2015 22:29:44 +0100	[thread overview]
Message-ID: <20151203212944.GB17308@twins.programming.kicks-ass.net> (raw)
In-Reply-To: <1449177740-5422-2-git-send-email-andi@firstfloor.org>

On Thu, Dec 03, 2015 at 01:22:20PM -0800, Andi Kleen wrote:
> +		/*
> +		 * On some CPUs the PEBS status can be zero when PEBS is
> +		 * racing with clearing of GLOBAL_STATUS.
> +		 *
> +		 * Normally we would drop that record, but in the
> +		 * case when there is only a single active PEBS event
> +		 * we can assume it's for that event.
> +		 */
> +		if (!pebs_status && cpuc->pebs_enabled &&
> +			!(cpuc->pebs_enabled & (cpuc->pebs_enabled-1)))
> +			pebs_status = cpuc->pebs_enabled;
> +
>  		bit = find_first_bit((unsigned long *)&pebs_status,
>  					x86_pmu.max_pebs_events);
>  		if (bit >= x86_pmu.max_pebs_events)


Ah! I think this is the comment I just asked for.



  reply	other threads:[~2015-12-03 21:29 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-03 21:22 [PATCH 1/2] x86, perf: Remove warning for zero PEBS status Andi Kleen
2015-12-03 21:22 ` [PATCH 2/2] x86, perf: Allow zero PEBS status with only single active event Andi Kleen
2015-12-03 21:29   ` Peter Zijlstra [this message]
2016-01-06 18:50   ` [tip:perf/core] perf/x86: " tip-bot for Andi Kleen
2015-12-03 21:28 ` [PATCH 1/2] x86, perf: Remove warning for zero PEBS status Peter Zijlstra
2016-01-06 18:50 ` [tip:perf/core] perf/x86: " tip-bot for Andi Kleen

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=20151203212944.GB17308@twins.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=ak@linux.intel.com \
    --cc=andi@firstfloor.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.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