From: Alexander Shishkin <alexander.shishkin@linux.intel.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: Ingo Molnar <mingo@redhat.com>,
linux-kernel@vger.kernel.org, vince@deater.net,
eranian@google.com, johannes@sipsolutions.net,
Arnaldo Carvalho de Melo <acme@infradead.org>
Subject: Re: [PATCH 2/7] perf: Generalize task_function_call()ers
Date: Mon, 11 Jan 2016 12:44:48 +0200 [thread overview]
Message-ID: <877fjg9yzj.fsf@ashishki-desk.ger.corp.intel.com> (raw)
In-Reply-To: <20151218090129.GQ6373@twins.programming.kicks-ass.net>
Peter Zijlstra <peterz@infradead.org> writes:
> On Thu, Dec 17, 2015 at 04:07:32PM +0100, Peter Zijlstra wrote:
>> On Thu, Dec 17, 2015 at 04:25:14PM +0200, Alexander Shishkin wrote:
>>
>> > That aside, why I brought it up in the first place is because the two
>> > functions are asymmetric: one is called with irqs disabled and the
>> > other -- with ctx::lock held (and not because I'm into bikeshedding or
>> > anything like that). Looking at the pair of them sets off my "that's not
>> > right" trigger and sends me to the event_function_call()
>> > implementation. So in that sense, prepending an extra underscore kind of
>> > made sense. Maybe __perf_remove_from_context_{on,off}()?
>>
>> You are quite right, and I think I've found more problems because of
>> this. Let me prod at this some more.
>
> So this then...
>
> This fixes, I think, 3 separate bugs:
>
> - remove_from_context used to clear ->is_active, this is against the
> update rules from ctx_sched_in() which set ->is_active even though
> there might be !nr_events
>
> - install_in_context did bad things to cpuctx->task_ctx; it would not
> validate that ctx->task == current and could do random things because
> of that.
>
> - cpuctx->task_ctx tracking was iffy
>
> It also unifies a lot of the weird and fragile code we had around all
> those IPI calls and adds a bunch of assertions.
>
> It seems to survive a little pounding with 'normal' workloads.
>
> Please have an extra careful look..
I notice that you dropped this from your queue, do you have any plans to
proceed with this, or should I pick it up?
Regards,
--
Alex
next prev parent reply other threads:[~2016-01-11 10:44 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-03 10:32 [PATCH 0/7] perf: Untangle aux refcounting Alexander Shishkin
2015-12-03 10:32 ` [PATCH 1/7] perf: Refuse to begin aux transaction after aux_mmap_count drops Alexander Shishkin
2015-12-03 10:32 ` [PATCH 2/7] perf: Generalize task_function_call()ers Alexander Shishkin
2015-12-03 17:34 ` Peter Zijlstra
2015-12-08 16:42 ` Alexander Shishkin
2015-12-08 16:57 ` Peter Zijlstra
2015-12-17 13:40 ` Peter Zijlstra
2015-12-17 14:25 ` Alexander Shishkin
2015-12-17 15:07 ` Peter Zijlstra
2015-12-18 9:01 ` Peter Zijlstra
2015-12-18 15:07 ` Alexander Shishkin
2015-12-18 16:47 ` Peter Zijlstra
2015-12-18 17:41 ` Alexander Shishkin
2015-12-21 14:39 ` Alexander Shishkin
2016-01-11 10:44 ` Alexander Shishkin [this message]
2015-12-03 10:32 ` [PATCH 3/7] perf: Add a helper to stop running events Alexander Shishkin
2015-12-03 10:32 ` [PATCH 4/7] perf: Free aux pages in unmap path Alexander Shishkin
2015-12-04 17:02 ` Peter Zijlstra
2015-12-04 22:17 ` Peter Zijlstra
2015-12-07 16:16 ` Peter Zijlstra
2015-12-09 9:57 ` Alexander Shishkin
2015-12-09 10:56 ` Peter Zijlstra
2015-12-10 11:20 ` Alexander Shishkin
2015-12-10 12:58 ` Alexander Shishkin
2015-12-03 10:32 ` [PATCH 5/7] perf: Document aux api usage Alexander Shishkin
2015-12-03 20:36 ` Mathieu Poirier
2015-12-03 10:32 ` [PATCH 6/7] perf/x86/intel/pt: Move transaction start/stop to pmu start/stop callbacks Alexander Shishkin
2015-12-03 10:32 ` [PATCH 7/7] perf/x86/intel/bts: Move transaction start/stop to " Alexander Shishkin
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=877fjg9yzj.fsf@ashishki-desk.ger.corp.intel.com \
--to=alexander.shishkin@linux.intel.com \
--cc=acme@infradead.org \
--cc=eranian@google.com \
--cc=johannes@sipsolutions.net \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=vince@deater.net \
/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
all inboxes | Powered by JetHome®