Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp1811074pxb; Wed, 9 Feb 2022 05:08:03 -0800 (PST) X-Google-Smtp-Source: ABdhPJxelZXPNidXaWyJTWqd3axARLjmr1dtWZz8dH73eAVOF5e9c7hs1SqYSw1vkdGP/ZMO/peK X-Received: by 2002:a05:6a00:170b:: with SMTP id h11mr1734176pfc.78.1644412083400; Wed, 09 Feb 2022 05:08:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644412083; cv=none; d=google.com; s=arc-20160816; b=iEoQZnHCU0hw32FikW9RXrjvev8IvYOE6p6LdvyEnbO/Uabn18WOU60LFQuaraZWl9 1Y+nL2aeqJ21y7X9BBKnU+NgvJC+Jptk7d1wMKPfC6f7sEFl+gWDy36RL5BFc0Qij2b6 DXMtXVHA0C6BLpexF5g3yuLyRRIyhewxTmj+h1FjzyQzDUhAt6Lc/5fBJQcCyJ2BzKA6 Cn5yPW9iu0LvLOJ0z1M6tSdy4g8zCLdjbXRKDjcZrTon3u5+7Umf9VBQ1Z4K3L1ikK+T Fk2g3Tpxp6QPdraua93kFnBEAba+mj912cBkw4UZZ+ad/r5pinyCaejagPIsGraLo2/2 b7RQ== 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:dkim-signature; bh=AtUNZ4s01M6g6RdXvEjIliRhqQEYsPwz6AWii/ZtLpg=; b=KaL3NujSOtgSW9wgkOks20oWOed0jp4x0WUrO8CDOxsrLTU1SDalYDJcUC/ptVjXzB GIMzSTMbHCFK3bmIID5tvD4IiBRawnv4I0MmZ/taRFo3azou/KSFVSRQIkNI+rtAXd91 IhJaD6FePi+6obtf5+NkFMJzcBLJcV++DU6jKMUCnfeKfGdyPeZ7GELV/PrP2D+0dkCS 0McRMmUwHd+gcr00VmoL8pdi5pXPal8PzRsDLtQQkOR5Rt+Jc1FY94aDUdrDdcbrvxg5 Xjq1uwETeeWOmqRzhB3XxQhqQCvd9amGjnfT2Hztbj4nO3xdLdDSYlEsPvESmVlp5IUo 4Ehg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=dNpieonr; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id h14si17826469pfh.343.2022.02.09.05.08.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Feb 2022 05:08:03 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=dNpieonr; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id A2973E03923A; Wed, 9 Feb 2022 02:35:36 -0800 (PST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234903AbiBIJlI (ORCPT + 99 others); Wed, 9 Feb 2022 04:41:08 -0500 Received: from gmail-smtp-in.l.google.com ([23.128.96.19]:40558 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234846AbiBIJiv (ORCPT ); Wed, 9 Feb 2022 04:38:51 -0500 Received: from desiato.infradead.org (desiato.infradead.org [IPv6:2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0CCFCC003641 for ; Wed, 9 Feb 2022 01:38:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=AtUNZ4s01M6g6RdXvEjIliRhqQEYsPwz6AWii/ZtLpg=; b=dNpieonr1BtMyKj8yCUtfbkPtJ 3kLQTSK4DVNughTfQzVLdIcHgdh+CAFZC06vZaMlhQmDu2SeTL5icfhy/Q9sJxWj/2umgUBPQA2hR UdHF8vSVgnqEEK74YWOpJ7VKEHUT7dP6EY4DrM5poXhmtiHpFd9uFHDh7kkWWMkEynKScNxn/Ivb3 KCV0x2lTs1/QfOZ6nXxE9+LW4ORVEMoItBIyOh+sEy6SX86PRzZ/tWLQU4iQd219iqdZl0q12dhoS 0kECkfWzx+LEQ58oQpctjG5QjlvcHXLYRMLs4LzAu/uUiY0lMVa8vNUJHDK7ril4mqTU7cqHUc4ZI dfG1KdTA==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=worktop.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nHjQj-008NfZ-Sd; Wed, 09 Feb 2022 09:38:30 +0000 Received: by worktop.programming.kicks-ass.net (Postfix, from userid 1000) id B82F89853C7; Wed, 9 Feb 2022 10:38:28 +0100 (CET) Date: Wed, 9 Feb 2022 10:38:28 +0100 From: Peter Zijlstra To: Mel Gorman Cc: Ingo Molnar , Vincent Guittot , Valentin Schneider , Aubrey Li , Barry Song , Mike Galbraith , Srikar Dronamraju , Gautham Shenoy , K Prateek Nayak , LKML Subject: Re: [PATCH v6 0/2] Adjust NUMA imbalance for multiple LLCs Message-ID: <20220209093828.GL23216@worktop.programming.kicks-ass.net> References: <20220208094334.16379-1-mgorman@techsingularity.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220208094334.16379-1-mgorman@techsingularity.net> X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 Tue, Feb 08, 2022 at 09:43:32AM +0000, Mel Gorman wrote: > Changelog sinve v5 > o Fix off-by-one error > > Changelog since V4 > o Scale imbalance based on the top domain that prefers siblings > o Keep allowed imbalance as 2 up to the point where LLCs can be overloaded > > Changelog since V3 > o Calculate imb_numa_nr for multiple SD_NUMA domains > o Restore behaviour where communicating pairs remain on the same node > > Commit 7d2b5dd0bcc4 ("sched/numa: Allow a floating imbalance between NUMA > nodes") allowed an imbalance between NUMA nodes such that communicating > tasks would not be pulled apart by the load balancer. This works fine when > there is a 1:1 relationship between LLC and node but can be suboptimal > for multiple LLCs if independent tasks prematurely use CPUs sharing cache. > > The series addresses two problems -- inconsistent logic when allowing a > NUMA imbalance and sub-optimal performance when there are many LLCs per > NUMA node. > > include/linux/sched/topology.h | 1 + > kernel/sched/fair.c | 30 ++++++++++--------- > kernel/sched/topology.c | 53 ++++++++++++++++++++++++++++++++++ > 3 files changed, 71 insertions(+), 13 deletions(-) Thanks!