[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150521141034.GT3644@twins.programming.kicks-ass.net>
Date: Thu, 21 May 2015 16:10:34 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Stephane Eranian <eranian@...gle.com>
Cc: Ingo Molnar <mingo@...nel.org>,
Vince Weaver <vincent.weaver@...ne.edu>,
Jiri Olsa <jolsa@...hat.com>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 03/10] perf/x86: Correct local vs remote sibling state
On Thu, May 21, 2015 at 06:31:25AM -0700, Stephane Eranian wrote:
> On Thu, May 21, 2015 at 4:17 AM, Peter Zijlstra <peterz@...radead.org> wrote:
> > For some obscure reason the current code accounts the current SMT
> > thread's state on the remote thread and reads the remote's state on
> > the local SMT thread.
> >
> > While internally consistent, and 'correct' its pointless confusion we
> > can do without.
> >
> > Flip them the right way around.
> >
> So you are changing the logic here from:
>
> * EXCLUSIVE: sibling counter measuring exclusive event
> * SHARED : sibling counter measuring non-exclusive event
> * UNUSED : sibling counter unused
>
> to:
>
> * EXCLUSIVE: current thread is using an exclusive event
> * SHARED: current thread is using a non-exclusive event
> * UNUSED: current thread is not using this counter
>
> I am okay with this just need to make sure there were no
> assumptions made about that. I will look.
Right; and when we construct the constraint mask we look at the other
one too. So both on the update and the read side I flipped things
around.
And that is really the only thing that matters, that you look at the
other sibling's thread state when constructing that mask. And that's
kept invariant.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists