From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754854AbbEOTGm (ORCPT ); Fri, 15 May 2015 15:06:42 -0400 Received: from mx1.redhat.com ([209.132.183.28]:40149 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753705AbbEOTGl (ORCPT ); Fri, 15 May 2015 15:06:41 -0400 Message-ID: <55564395.70406@redhat.com> Date: Fri, 15 May 2015 15:05:57 -0400 From: Rik van Riel User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: Peter Zijlstra , mingo@kernel.org CC: dedekind1@gmail.com, linux-kernel@vger.kernel.org, mgorman@suse.de, rostedt@goodmis.org, juri.lelli@arm.com Subject: Re: [RFC][PATCH 4/4] sched, numa: Ignore pinned tasks References: <20150515154333.712161952@infradead.org> <20150515154833.726258767@infradead.org> In-Reply-To: <20150515154833.726258767@infradead.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 05/15/2015 11:43 AM, Peter Zijlstra wrote: > Per cpu (kernel) threads can currently trick the load balancer in > thinking there's something to do and result in moving perfectly placed > tasks away. > > By virtue of the new do_set_cpus_allowed() we can easily add nr_pinned > accounting. Which we'll use to change the fbq classification such that > we make it less likely to pick such tasks for migration. > > Note that it is still possible we'll migrate these well placed tasks > away, further patches could reduce this still. A few ideas here :) - Identify whether the current task on a CPU is the one that would like to migrate, and treat the runqueue as "movable" instead of "remote" if none of the runnable but queued tasks want to migrate away. - Teach can_migrate_task about the fbq types, and have it enforce NUMA placement when the type is "remote", and ignore NUMA placement when we know there are no good tasks to move. This might require another simplification of migrate_improves/degrades_locality. > Suggested-by: Rik van Riel > Signed-off-by: Peter Zijlstra (Intel) Reviewed-by: Rik van Riel -- All rights reversed