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: <20140516141745.GU11096@twins.programming.kicks-ass.net>
Date:	Fri, 16 May 2014 16:17:45 +0200
From:	Peter Zijlstra <peterz@...radead.org>
To:	Preeti Murthy <preeti.lkml@...il.com>
Cc:	Ben Segall <bsegall@...gle.com>, Ingo Molnar <mingo@...hat.com>,
	LKML <linux-kernel@...r.kernel.org>,
	Preeti U Murthy <preeti@...ux.vnet.ibm.com>
Subject: Re: [PATCH] sched: fix exec_start/task_hot on migrated tasks

On Fri, May 16, 2014 at 07:27:32PM +0530, Preeti Murthy wrote:
> > 0 isn't strictly the right thing to do here, since the clock can wrap,
> > but being wrong every ~585 years isn't too big an issue for this.
> 
> I don't understand this. Will setting it to 0 not indicate beginning
> of ticking? 

In modular spaces there is no beginnings nor endings.

> So when you find out for how long the task has run, the
> difference would be larger than what would have been had you
> let exec_start be at its previous value of the old cpu's clock_task right?

Nope, see the modular space thing, once every ~585 years we'll wrap the
clock and 0 is within range of recently ran.

> Will not setting exec_start to the clock_task of the destination rq
> during migration be better? This would be the closest we could
> come to estimating the amount of time the task has run on this new
> cpu while deciding task_hot or not no?

Setting it to the exact clock_task of the destination rq would make it
hot on that rq, even though it hasn't yet ran there, so you'd have to do
something like: rq_clock_task(dst_rq) - sysctl_sched_migration_cost.

But seeing as how that is far more work, and all this is heuristics
anyhow and an extra fail term of 1/585 years is far below the current
fail rate, all is well.

Content of type "application/pgp-signature" skipped

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ