[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170519110951.afpvoewwmszdnob5@hirez.programming.kicks-ass.net>
Date: Fri, 19 May 2017 13:09:51 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Aaron Lu <aaron.lu@...el.com>
Cc: linux-kernel@...r.kernel.org, Ingo Molnar <mingo@...nel.org>,
Thomas Gleixner <tglx@...utronix.de>,
Tim Chen <tim.c.chen@...ux.intel.com>,
Dave Hansen <dave.hansen@...el.com>,
Huang Ying <ying.huang@...el.com>
Subject: Re: [PATCH resend] smp: avoid sending needless IPI in
smp_call_function_many()
On Fri, May 19, 2017 at 03:53:31PM +0800, Aaron Lu wrote:
> @@ -434,6 +442,7 @@ void smp_call_function_many(const struct cpumask *mask,
> if (unlikely(!cpumask_weight(cfd->cpumask)))
> return;
Another thing that occurred to me while staring at that function, is
that we could move:
cpumask_and(cfd->cpumask, mask, cpu_online_mask);
to the very begin of that function, that would then obviate the need for
that cpumask_weight() test afaict.
I'm not sure its worth the trouble, but it would make the function
slightly easier to look at.
Powered by blists - more mailing lists