Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3416340pxv; Mon, 26 Jul 2021 03:51:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwbvPLlDMfZgcxxuD4lxd1ZqAjFG73ulQ2h3IBcZar3DlYtnp/GxIw8GPRBayEkWge+CUA3 X-Received: by 2002:a17:906:410a:: with SMTP id j10mr1687379ejk.167.1627296686854; Mon, 26 Jul 2021 03:51:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627296686; cv=none; d=google.com; s=arc-20160816; b=cdOnRUOejAD3ayeNjkJz1eli+cAUd+znkn4h5ty3MaiicfKVb1PSDlNo34KhG2nbsL Q++vtHCSeyZrXBvosBZh0qlbfNLgbry1lYOpIFFVWR+gCNxgoCf2QRB+hTF/2fgCqzeU y1hevaphvke+k9A8nN7YaNNzlgzf5luIIMt4coTb3rKed1fP5eezfGWgyN1ZmAFUYZZA Z16ozqncgciEpN45dJGB1ZGyKP+qHuf8cuknp2qziLH+9fx4/FxdmGGsR6T1rkqIfbJ8 zQx5rDaY+CB9fsazYnc47I3SJq82fxtQAYgyvUKJCrAqBxmzfHq8iEiuCU++1JGt5NOd L9ZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=spEnAdqe8q1P5++yANdQysSJPDuS26PszjMIX0Yar4c=; b=Y0RbT8i4P3bRzVvs5tjBHFEH1hspWYjEZPUgVWAkBWH9jazTLaBOx+q32bOHNgfwV1 1e91NNjVioASXd2l6V/icz8E+eFEAjWqtwKlUydxUG97VzGm7RX9qpUt6HLODcDX9DK3 n3iPuwJMDm5LXqeThDFERRzAtgd0t7G5vv4Vry0iifGqw2Mgrsx9SfK6GEic9tcSIgQo VurAcHsPB8xvaCucStBDjIHsgXjrGz+OKpbO7B9ZuSVbGbOVnoIxoN/mAiW76sHZo4+I mLHeEo0Zmim4Uc7CAtpHY55MbTQmrIrZwXdUmF5+blGdyoGGPuEGAflLCbHJ1Nd/XVk6 rcSw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ga29si5397098ejc.74.2021.07.26.03.51.02; Mon, 26 Jul 2021 03:51:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231792AbhGZJmb (ORCPT + 99 others); Mon, 26 Jul 2021 05:42:31 -0400 Received: from outbound-smtp57.blacknight.com ([46.22.136.241]:40643 "EHLO outbound-smtp57.blacknight.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229593AbhGZJma (ORCPT ); Mon, 26 Jul 2021 05:42:30 -0400 Received: from mail.blacknight.com (pemlinmail06.blacknight.ie [81.17.255.152]) by outbound-smtp57.blacknight.com (Postfix) with ESMTPS id 7E86EFA752 for ; Mon, 26 Jul 2021 11:22:58 +0100 (IST) Received: (qmail 21543 invoked from network); 26 Jul 2021 10:22:58 -0000 Received: from unknown (HELO stampy.112glenside.lan) (mgorman@techsingularity.net@[84.203.17.255]) by 81.17.254.9 with ESMTPA; 26 Jul 2021 10:22:58 -0000 From: Mel Gorman To: LKML Cc: Ingo Molnar , Peter Zijlstra , Vincent Guittot , Valentin Schneider , Aubrey Li , Mel Gorman Subject: [RFC PATCH 0/9] Modify and/or delete SIS_PROP Date: Mon, 26 Jul 2021 11:22:38 +0100 Message-Id: <20210726102247.21437-1-mgorman@techsingularity.net> X-Mailer: git-send-email 2.26.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org When scanning for an idle CPU, SIS_PROP limits the scan based on an average estimated idle time for a domain but it's a somewhat inconsistent and fuzzy heuristic. Idle time of a CPU does not necessarily correlate with idle time of a domain, scanning for an idle core is not throttled at all and successful scans are not accounted for. The first three patches are accounting patches to put some numbers on the scan efficiency. Ultimately, they may not be merged but they are useful for determining if a patch works as advertised. Patch 4 improves recent_used_cpu to reduce the amount of scanning that is done in absolute terms. Patch 5 notes that the target CPU has already been scanned with select_idle_cpu starts and therefore should be skipped. Patches 6-9 replace SIS_PROP with a scheme based on partially tracking idle CPUs, first proposed by Aubrey Li and modified by this series. It is likely to be the most controversial, not necessary a win, but the possibility was discussed. The series is likely to be split with one series being patches 4-5 and a second being patches 6-9. The series is not a univeral win or loss but there are some improvements and overall, scan efficiencies are improved. A limiting factor in the evaluation is that tracking the statistics is expensive on its own and all tests were run with schedstat enabled. Depending on how this RFC is received, testing would be done without schedstat and the series may be split. include/linux/sched/topology.h | 13 +++ kernel/sched/core.c | 7 +- kernel/sched/debug.c | 8 ++ kernel/sched/fair.c | 149 ++++++++++++++++++--------------- kernel/sched/features.h | 5 -- kernel/sched/idle.c | 5 ++ kernel/sched/sched.h | 17 +++- kernel/sched/stats.c | 10 ++- kernel/sched/topology.c | 3 +- 9 files changed, 133 insertions(+), 84 deletions(-) -- 2.26.2