Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp1696570ybh; Fri, 13 Mar 2020 05:56:37 -0700 (PDT) X-Google-Smtp-Source: ADFU+vvVqZCQnYd0LZJ1MZQbbUOG9dXad6L0urgrV8UWw2OhnoZCEqMwNIIw+kbF4WlUyNWVpBuw X-Received: by 2002:aca:bfc2:: with SMTP id p185mr7069859oif.57.1584104196995; Fri, 13 Mar 2020 05:56:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584104196; cv=none; d=google.com; s=arc-20160816; b=tYDeUTLGFAkrM9iSUwrcVgNAyZ7lTuj3jA93bux1P2UbQn7a7izb72wDmaanwYc4t2 qZ4CGkwUGd0kstMaGw6h9Z1Z9QFmPCvYrP4uAVtSo2QegP0VP7nzEX81ICUgYTIw0P1d iorbezNH8xMapqNl1X7cVj8OR8BWQuDYID+VLltzas5Tx2678yOTRDPiv9iEyKJYaWMp V+ky5ysSpD8D6NySOZlG+jRUFe7nJKhYRwNrj8PITgkdmq4nhxuF/vvLC6Ft1/LhL8c7 tCX7PZnNw51AAzPz5Ppw/y73VScXR6K7BwxhHt89wuhPiVcrJZ9c1U+9a9wpr+SPyEAh 7nQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=CpV/S5dRh3Z14cEhftotr9GJXEKt0+TwJPXh+2tNvD8=; b=0W/85u4N+BgwUW2f3t6UzR3jlqWHMIe/MdRU96YgS/bRtXhzByrANQpB6pq72iQ76Y UN1b3wVhmqpKR0igytGTFYSPIqjjRuibhRisKRknNAITUbH5+1a8zzHTEM2uwspO3e8A vvW3lxPhKOg1XsSohw/o7yXik4if0v4LG59yArk328YR6pdOloarPZYKedNuVoe2itwB KUefW5xJTIc0fTvRGe1P34CjINXCD5wiW19ppr/lFLpstlJuVpzn+GST9VsMtIfUpWBZ Sd5ba+ZdVUq/1NeyKdnslDJIEzFmW2H6Jnrqfq1lw+mtb9N4kuk1XpOCT3diABbkuwRk rxaQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=T4JYaeuk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j206si4470909oia.158.2020.03.13.05.56.24; Fri, 13 Mar 2020 05:56:36 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=T4JYaeuk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726741AbgCMMze (ORCPT + 99 others); Fri, 13 Mar 2020 08:55:34 -0400 Received: from mail-lf1-f67.google.com ([209.85.167.67]:44239 "EHLO mail-lf1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726216AbgCMMzd (ORCPT ); Fri, 13 Mar 2020 08:55:33 -0400 Received: by mail-lf1-f67.google.com with SMTP id b186so7681439lfg.11 for ; Fri, 13 Mar 2020 05:55:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=CpV/S5dRh3Z14cEhftotr9GJXEKt0+TwJPXh+2tNvD8=; b=T4JYaeuknvc4qLFnfdDNS+L23u70exnEXshCWS8mkjZHF1TaK4rTP8ehcfofCLDzlE Cvgt/yW0FrVbyeH7lvpJ8pYpdVivnLQ9dp/5jjKdi/Et8vt/PEbtlNB3oWJJ63xWoOK1 U3nQzyElFPTKWv/ou2whD6H52+osMi0WLv1rI58mxelQjaGhC4Z6P2ZCx3oJrgHJF7r4 2iQoh9JRy+RBWEz8K02QlO5WQE+TAeXq0EHBFwApsfXrfOQrXe9C5b3kh7UjRQsGfFwQ v7LzlpusC/5r+vInNPRG0aJ2JJanH5jjTLNIkmbibdZiix8EzCE3G7/SOTP0ahLdgWiQ yURg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=CpV/S5dRh3Z14cEhftotr9GJXEKt0+TwJPXh+2tNvD8=; b=ZXnsUbg7zMh3QiiIDTuwa/5jb52heV9NEcWhMYG3dg5VfZ2ucztQw1N3j8OS9UCcfk VxgV0U1YNGpxzgo/Lqg/y9B4DKLVMmu9QyUEDrCol5MJgVg7ejmqK7GMs5leycGqJGwg vxmIIh9K0o3CEGXJJ7v+HkbMvOgw9yMKw1tjThTC7FYBMEECHfQsqWIXSSBKgoR+aa9W ZZXeWUlgdEz3MZTJI1nxHJF8YIGLvVA89IqV4YXFoL7dfkU04JgZzd7nrCG/P7xOeizx IulCg6RVfezRb/pr6QIgSeKI05CpqvdKB45f3SawbwEPHzATrboI4RSjDsaWD4g3XEs7 ay6g== X-Gm-Message-State: ANhLgQ2KrDr/sp/Bm/Ft+fgRytC5hTl85NgGLu5yQfY03IVHkpDX3dOz EFOH6B8/tPCzcHjaUwdTDfeSOMVU3ALzgLc6tflsww== X-Received: by 2002:ac2:5605:: with SMTP id v5mr8714363lfd.184.1584104131957; Fri, 13 Mar 2020 05:55:31 -0700 (PDT) MIME-Version: 1.0 References: <20200312165429.990-1-vincent.guittot@linaro.org> In-Reply-To: From: Vincent Guittot Date: Fri, 13 Mar 2020 13:55:20 +0100 Message-ID: Subject: Re: [PATCH] sched/fair: improve spreading of utilization To: Valentin Schneider Cc: Ingo Molnar , Peter Zijlstra , Juri Lelli , Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , linux-kernel Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 13 Mar 2020 at 13:42, Valentin Schneider wrote: > > > On Fri, Mar 13 2020, Valentin Schneider wrote: > > On Fri, Mar 13 2020, Vincent Guittot wrote: > >>> > diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c > >>> > index 3c8a379c357e..97a0307312d9 100644 > >>> > --- a/kernel/sched/fair.c > >>> > +++ b/kernel/sched/fair.c > >>> > @@ -9025,6 +9025,14 @@ static struct rq *find_busiest_queue(struct lb_env *env, > >>> > case migrate_util: > >>> > util = cpu_util(cpu_of(rq)); > >>> > > >>> > + /* > >>> > + * Don't try to pull utilization from a CPU with one > >>> > + * running task. Whatever its utilization, we will fail > >>> > + * detach the task. > >>> > + */ > >>> > + if (nr_running <= 1) > >>> > + continue; > >>> > + > >>> > >>> Doesn't this break misfit? If the busiest group is group_misfit_task, it > >>> is totally valid for the runqueues to have a single running task - > >>> that's the CPU-bound task we want to upmigrate. > >> > >> group_misfit_task has its dedicated migrate_misfit case > >> > > > > Doh, yes, sorry. I think my rambling on ASYM_PACKING / reduced capacity > > migration is still relevant, though. > > > > And with more coffee that's another Doh, ASYM_PACKING would end up as > migrate_task. So this only affects the reduced capacity migration, which yes ASYM_PACKING uses migrate_task and the case of reduced capacity would use it too and would not be impacted by this patch. I say "would" because the original rework of load balance got rid of this case. I'm going to prepare a separate fix for this > might be hard to notice in benchmarks.