Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp1702397pxb; Thu, 14 Apr 2022 11:59:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzAJgGzReCSDIF5tUXpaV/EcJ76WvRb8iWWEx53Gj7oVJHKY+jCW/aXccPN5q2qiN4uPRNi X-Received: by 2002:a17:90b:354a:b0:1cd:db3a:8f87 with SMTP id lt10-20020a17090b354a00b001cddb3a8f87mr49806pjb.44.1649962785264; Thu, 14 Apr 2022 11:59:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649962785; cv=none; d=google.com; s=arc-20160816; b=zzapY0vrh11hoc051BtseI4w0JPHNt+Tbvt56ZNdn07MWEYDIb0ICW0s0kpehAbbx4 XAAJSHMtNhlFywvOabABufFbNIO3ENpwEsJA4rZ9vZa3zelP5xhE+DgZDaLTiu4lPKfL UmV2LDS5a/HGhjZTTPkVX39Wls/qvOjoPvL4Eo8Zdo1pBI+1l6bK7pvJobU91eunN+z/ JCUz3bhmv68ga0+D+A2Nj8qg71IEA2qWWLKg74OXwgGzhjW94nGwE1rHiai9zLU9HF36 sRtk/gB4O8Cy58N81wd2NGXVonIoV0tUTs3dFXwMyxK88dit7/PpoIAyZ4nkvrtup2GI G6Uw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=bPArHdMU6HCGhQlzhm4WXmML8t4K0TJTv+dbhX3v3/E=; b=XipJmYgfqiMEjENczWLqnqC2tN2flAlbQQaWIsk6BLwZ9dZVvTxNmoUu0UGil0NxoP U/MHtsSVjkMY6eiwMjhbSnUG3X3wT8eQtiqIuere6lihoYSrcFEHO1n52FvEl0X/l8sX KRhp97hpdDGweOFJjrvbzE7wIINjJR6P+DK3vwek2tseyscDLRXGSkgARqSfWtKIXzvv 6yZODLLHGsi/T2NObSbYnZhe4vqA4dXSZE14x1vOCQAOtCgSQ7NiAY/NXax5KqWzdvkA rIDRTsekLI/lKBVsYHf+sJmm88ISQr57OsWaU2nLCDABQ8nsfkAF84ZooQgKyBh46Tbx 6VvA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id kb5-20020a17090ae7c500b001c6ae0e6de0si2077694pjb.34.2022.04.14.11.59.30; Thu, 14 Apr 2022 11:59:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237574AbiDMX74 (ORCPT + 99 others); Wed, 13 Apr 2022 19:59:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45160 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231635AbiDMX7z (ORCPT ); Wed, 13 Apr 2022 19:59:55 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 14AF655497 for ; Wed, 13 Apr 2022 16:57:32 -0700 (PDT) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id BD9971424; Wed, 13 Apr 2022 16:57:31 -0700 (PDT) Received: from airbuntu (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 1ECF93F73B; Wed, 13 Apr 2022 16:57:29 -0700 (PDT) Date: Thu, 14 Apr 2022 00:57:19 +0100 From: Qais Yousef To: Vincent Guittot Cc: David Laight , Dietmar Eggemann , "mingo@redhat.com" , "peterz@infradead.org" , "juri.lelli@redhat.com" , "rostedt@goodmis.org" , "bsegall@google.com" , "mgorman@suse.de" , "linux-kernel@vger.kernel.org" , "parth@linux.ibm.com" , "chris.hyser@oracle.com" , "pkondeti@codeaurora.org" , "Valentin.Schneider@arm.com" , "patrick.bellasi@matbug.net" , "pjt@google.com" , "pavel@ucw.cz" , "tj@kernel.org" , "qperret@google.com" , "tim.c.chen@linux.intel.com" , Wei Wang Subject: Re: Scheduling tasks on idle cpu Message-ID: <20220413235719.xs72pm2kgihia46g@airbuntu> References: <030aacb0c1304e43ab917924dcf4f138@AcuMS.aculab.com> <20220411233447.rcencjivkhyltyxm@airbuntu> <4ca5cd70904d47bea0df93f7c0979c66@AcuMS.aculab.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/12/22 11:07, Vincent Guittot wrote: > On Tue, 12 Apr 2022 at 10:39, David Laight wrote: > > Yes I want the CFS scheduler to pick an idle cpu in preference > > to an active RT one. > > When task 34512 wakes up, scheduler checks if prev or this cpu are > idle which is not the case for you. Then, it compares the load of prev > and this_cpu and seems to select this_cpu (cpu17). > > Once cpu17 selected, it will try to find an idle cpu which shares LLC > but it seems that the scheduler didn't find one and finally keeps task > 34512 on this_cpu. > > Note that during the next tick, a load balance will be trigger if > this_cpu still have both RT and task 34512, David said there are idle cpus " There are two physical cpu with 20 cores each (with hyperthreading). 16, 18, 34, 36 and 38 were idle. So both 16 and 18 should be on the same NUMA node. All the others are running the same RT thread code. " Except for the possibility of them becoming idle just after the task has woken up, shouldn't one of them have been picked? Thanks -- Qais Yousef