lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190211104427.GX32511@hirez.programming.kicks-ass.net>
Date:   Mon, 11 Feb 2019 11:44:27 +0100
From:   Peter Zijlstra <peterz@...radead.org>
To:     Viresh Kumar <viresh.kumar@...aro.org>
Cc:     Ingo Molnar <mingo@...hat.com>,
        Vincent Guittot <vincent.guittot@...aro.org>,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] sched/fair: Improve the for loop in
 select_idle_core()

On Mon, Feb 11, 2019 at 03:56:59PM +0530, Viresh Kumar wrote:
> On 11-02-19, 10:30, Peter Zijlstra wrote:
> > On Thu, Feb 07, 2019 at 04:16:06PM +0530, Viresh Kumar wrote:
> > > @@ -6081,10 +6082,14 @@ static int select_idle_core(struct task_struct *p, struct sched_domain *sd, int
> > >  	for_each_cpu_wrap(core, cpus, target) {
> > >  		bool idle = true;
> > >  
> > > -		for_each_cpu(cpu, cpu_smt_mask(core)) {
> > > -			cpumask_clear_cpu(cpu, cpus);
> > > -			if (!available_idle_cpu(cpu))
> > > +		smt = cpu_smt_mask(core);
> > > +		cpumask_andnot(cpus, cpus, smt);
> > 
> > So where the previous code was like 1-2 stores, you just added 16.
> 
> Is the max number of possible threads per core just 2? That's what I
> read just now and I wasn't aware of that earlier. This commit doesn't
> improve anything then. Sorry for the noise.

We've got up to SMT8 in the tree (Sparc64, Power8 and some MIPS IIRC),
but that's still less than having to touch the entire bitmap.

Also, Power9 went back to SMT4 and I think the majory of SMT deployments
is that or less.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ