Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp6813557ybi; Wed, 29 May 2019 13:40:10 -0700 (PDT) X-Google-Smtp-Source: APXvYqzfKxIEC2WaZqr8EzNJf/OvDfL8Q0m2gxHs8ug5gISubxxfED7GqvfnzVG4yRQumqDNupsA X-Received: by 2002:a62:1a51:: with SMTP id a78mr51884323pfa.39.1559162410843; Wed, 29 May 2019 13:40:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559162410; cv=none; d=google.com; s=arc-20160816; b=ai9jUh3ebPHt4XuDd+WA9JBSFrN9uXIAjYl1uROprBQx8f9QNWsjmKxGKtPzANHEb0 T1jtupDtHVtjVoun0YW6IeyxIxurY0h88h03pITIlJvIZyShiHjn+U18VbFK5ntnQQGy seTT1WskQuv4CZo60eycYJSoJeLP6ql2g9wDpMvKstxthgNSdh21SXNAQDs2nxhGsubo ZgevwRPfLFxqLfwYlbNF1ZvXRhDhdlOPDGmuGJON+OPKyCL5mKnnrcXCtNvPJkBQLV4c 2kjJKahJckSwxZ6RMWByQomS+P/4e1+MBg5+U4zAr5u0N23xcEXorDA1blYpJETGE0bf sr5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=TAplLGxgX6E2eCP7Vyrlwjs1jAbUhN21T+mgnkcj9Gw=; b=AyR+Iw0KVVToT3JAdTR/oHGMlCvinXbKJhowJ3UCyjw0Gr9Wdes6dxzIzJm6mhigYh V1qatQA6Mio7C0ulBdGz7uUPn3vkOifj2Z0D0BBynIyE+87Z5Teh6gVxU5sx13Alg/92 ARheMporjcm+G1MSlvKWBk++86th44mIOhwHNDnC5wZkKrT/yJykoLHnRsZ4suJKGrHB R3R0c75YIZCDatvQqw4rfsTsQNA4J/nu+uNNmQuRe4oH2Gb+sI/ImVzqryV5OlbMI1P2 ZsJI2qNNAJw3Qcr9kMpw1/rf1Sn42mH1xrtixvq66fnENliUPCIMPt1gzou0zMBRzhnR mffA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@digitalocean.com header.s=google header.b=MSPaLPn9; 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=REJECT sp=REJECT dis=NONE) header.from=digitalocean.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 64si778924pgi.366.2019.05.29.13.39.54; Wed, 29 May 2019 13:40:10 -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=@digitalocean.com header.s=google header.b=MSPaLPn9; 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=REJECT sp=REJECT dis=NONE) header.from=digitalocean.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726541AbfE2Ug6 (ORCPT + 99 others); Wed, 29 May 2019 16:36:58 -0400 Received: from mail-it1-f194.google.com ([209.85.166.194]:40300 "EHLO mail-it1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726139AbfE2Ug6 (ORCPT ); Wed, 29 May 2019 16:36:58 -0400 Received: by mail-it1-f194.google.com with SMTP id h11so5778470itf.5 for ; Wed, 29 May 2019 13:36:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=digitalocean.com; s=google; h=from:to:cc:subject:date:message-id; bh=TAplLGxgX6E2eCP7Vyrlwjs1jAbUhN21T+mgnkcj9Gw=; b=MSPaLPn9fnXCi+QtGNpxbOvNOOIbtFURFEypZNV40ABhsgzHo/HU9Z7ZIkuirZwkxe pS+pxvvaOZ2712I4y9kOjE3SQYmr6tPnkS4sIq8TeU7Ghz7197hKd/hSnVi0qO1lQVZ4 emHqQ8gTj+dy9jXduyIjRgGkF6tTOgOQ4KMy0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=TAplLGxgX6E2eCP7Vyrlwjs1jAbUhN21T+mgnkcj9Gw=; b=MB167gbnxuiq4Jdw89mvc2CA6o7Dr9b4elkSYA4qf9P1JeOu/Fk4DKfYhEwpKLEO3v yul8LMVsOAo3TNM5J+FOAcbpqKdUe8VmEOxG1bsDE3DY7qSqZ/cTFo8lKu0Qr3x835p4 KcIrYkXS4z2y1p8ULN9lLnuxAEShjD1p4siGj6vPsrlsMROqWWCevLAtds74C8+xXIBb nOAsZECtrwCFODJWSKHprCxpkXC5AlcjLQdnO/C5k80RJ17l+Gno5LXTVIoFPOoeUah7 eVu1dYro6LbvWTjhGNgPLxAr43FCK50hgeOSN/XotD+DtlqW7CzkMOtv/xVfo/bYzJY8 c2iQ== X-Gm-Message-State: APjAAAXPgJexDW3a/apSIicegamVv73a22Wcuydc6ytZpcmDBuF8OM3G vr0dqnFHunVA4n227etFybcKRA== X-Received: by 2002:a24:5592:: with SMTP id e140mr644itb.48.1559162217203; Wed, 29 May 2019 13:36:57 -0700 (PDT) Received: from swap-tester ([178.128.225.14]) by smtp.gmail.com with ESMTPSA id w194sm172506itb.33.2019.05.29.13.36.56 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 29 May 2019 13:36:56 -0700 (PDT) From: Vineeth Remanan Pillai To: Nishanth Aravamudan , Julien Desfossez , Peter Zijlstra , Tim Chen , mingo@kernel.org, tglx@linutronix.de, pjt@google.com, torvalds@linux-foundation.org Cc: Vineeth Remanan Pillai , linux-kernel@vger.kernel.org, subhra.mazumdar@oracle.com, fweisbec@gmail.com, keescook@chromium.org, kerrnel@google.com, Phil Auld , Aaron Lu , Aubrey Li , Valentin Schneider , Mel Gorman , Pawan Gupta , Paolo Bonzini Subject: [RFC PATCH v3 00/16] Core scheduling v3 Date: Wed, 29 May 2019 20:36:36 +0000 Message-Id: X-Mailer: git-send-email 2.17.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Third iteration of the Core-Scheduling feature. This version fixes mostly correctness related issues in v2 and addresses performance issues. Also, addressed some crashes related to cgroups and cpu hotplugging. We have tested and verified that incompatible processes are not selected during schedule. In terms of performance, the impact depends on the workload: - on CPU intensive applications that use all the logical CPUs with SMT enabled, enabling core scheduling performs better than nosmt. - on mixed workloads with considerable io compared to cpu usage, nosmt seems to perform better than core scheduling. Changes in v3 ------------- - Fixes the issue of sibling picking up an incompatible task - Aaron Lu - Vineeth Pillai - Julien Desfossez - Fixes the issue of starving threads due to forced idle - Peter Zijlstra - Fixes the refcounting issue when deleting a cgroup with tag - Julien Desfossez - Fixes a crash during cpu offline/online with coresched enabled - Vineeth Pillai - Fixes a comparison logic issue in sched_core_find - Aaron Lu Changes in v2 ------------- - Fixes for couple of NULL pointer dereference crashes - Subhra Mazumdar - Tim Chen - Improves priority comparison logic for process in different cpus - Peter Zijlstra - Aaron Lu - Fixes a hard lockup in rq locking - Vineeth Pillai - Julien Desfossez - Fixes a performance issue seen on IO heavy workloads - Vineeth Pillai - Julien Desfossez - Fix for 32bit build - Aubrey Li Issues ------ - Comparing process priority across cpus is not accurate TODO ---- - Decide on the API for exposing the feature to userland --- Peter Zijlstra (16): stop_machine: Fix stop_cpus_in_progress ordering sched: Fix kerneldoc comment for ia64_set_curr_task sched: Wrap rq::lock access sched/{rt,deadline}: Fix set_next_task vs pick_next_task sched: Add task_struct pointer to sched_class::set_curr_task sched/fair: Export newidle_balance() sched: Allow put_prev_task() to drop rq->lock sched: Rework pick_next_task() slow-path sched: Introduce sched_class::pick_task() sched: Core-wide rq->lock sched: Basic tracking of matching tasks sched: A quick and dirty cgroup tagging interface sched: Add core wide task selection and scheduling. sched/fair: Add a few assertions sched: Trivial forced-newidle balancer sched: Debug bits... include/linux/sched.h | 9 +- kernel/Kconfig.preempt | 7 +- kernel/sched/core.c | 858 +++++++++++++++++++++++++++++++++++++-- kernel/sched/cpuacct.c | 12 +- kernel/sched/deadline.c | 99 +++-- kernel/sched/debug.c | 4 +- kernel/sched/fair.c | 180 ++++---- kernel/sched/idle.c | 42 +- kernel/sched/pelt.h | 2 +- kernel/sched/rt.c | 96 ++--- kernel/sched/sched.h | 237 ++++++++--- kernel/sched/stop_task.c | 35 +- kernel/sched/topology.c | 4 +- kernel/stop_machine.c | 2 + 14 files changed, 1250 insertions(+), 337 deletions(-) -- 2.17.1