Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp3931110pxf; Mon, 22 Mar 2021 20:38:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyWKKp6Ealz3OmH7i4Cmkg0/69pye8eBiIGTLXO3hX4TVpjsQ1d6j6b0ZFXq6SV+yXKXiWK X-Received: by 2002:a17:906:78d:: with SMTP id l13mr2841011ejc.97.1616470693355; Mon, 22 Mar 2021 20:38:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616470693; cv=none; d=google.com; s=arc-20160816; b=qxr+4BmnwhH+tfuH/gVaKYWvbKPj8kULu25Ynt3hQ5GT9/BC4npbGTBFMCBO6DpJvh cWAVPk4lr9AkskRpwW0PurdMZDmZQkRx6y0ZLhlDLrwvzzeoJ0NOdYR913NK0dvekARi L8ftjSdPRX51jF+7/sO7eB56WYu7vTQq5MsxDKYv8Yr5fzK+7vREgKdF721Ex9oTVrkV 5olTcUMkH9CtbABhqCYPEZJ5qfy8tehfQxoR8iJFisJNeXWJxcee7nZWBSgzFOFp9pVW tqg9tbWPaz+5MOzAQ2ChKYho/xb5wNQ9ZAaV5cfAtXw8Gf4VnfftLce1g1K3u1U1KdcJ eSOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=WxWS/Gdj9HB8+LY4XIChbYX4Fz5bQD6zz9sFEv2H7Lg=; b=KNKXm4KnlNPsg8b9N65x6tDHn8F6E3bRMif0v5Zwpdp8QtMowrFzcvFHkwsqy50ktT JNwozd1WKddO5OzNHXnU99+0pRoRDk7DbQ7yLyph6VPE6MKprv2q1VbqcT10+9rPX44J tRQDp09ejF2gF3KSYbQ4iH2m6MpNBzDa18qOYzJvpkSmZxuDEgXwdf1Mn6MZHrM4brC5 /yVmsdPq6jlxj3Ks1OKbcir+Nu8jd37BLrXNeyKXYr/tA3u/Wa/TOUicvFc5JcfHg99W Jk6ywRADnmIU7BxTx1O1D6qVFigy4BwZeyYvSZZ/kwtENokr08V++JDWksmXzwtOFJjU qIGw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=IoftGevV; 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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l4si12228868eje.225.2021.03.22.20.37.50; Mon, 22 Mar 2021 20:38:13 -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; dkim=pass header.i=@google.com header.s=20161025 header.b=IoftGevV; 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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229893AbhCWDfs (ORCPT + 99 others); Mon, 22 Mar 2021 23:35:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49270 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229771AbhCWDff (ORCPT ); Mon, 22 Mar 2021 23:35:35 -0400 Received: from mail-qt1-x82b.google.com (mail-qt1-x82b.google.com [IPv6:2607:f8b0:4864:20::82b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A1D7DC061756 for ; Mon, 22 Mar 2021 20:35:34 -0700 (PDT) Received: by mail-qt1-x82b.google.com with SMTP id 94so14070304qtc.0 for ; Mon, 22 Mar 2021 20:35:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=WxWS/Gdj9HB8+LY4XIChbYX4Fz5bQD6zz9sFEv2H7Lg=; b=IoftGevVp32A8qjV/yrhPqxOcjTlqVrjANAxbFNRBdflMbRRNI7+mTNV1U3LdtuIo4 RA1pcVVbInzLI201oUijy/F+BnXvxpveh/jcSGvly/lj2aej8UGxA0KdoqztH5pOHqme HKesCOzRy2H3PWypJStIaUfZxjQ00LY6Esck3xNxJH4HFZGlKqwMzAwBnRoIseJDv8Z5 3spj96MYC02acTuPtn9+MP3kmhtrhzaGbS3Xd5zGXGVbZFJKW8SJgOkFkjl7FFn7yLBC 5LM5yEXJPy3ToLpB7tpL+Zi1FeFfnpU2WGvn7YKv9jksKoAvt/FIfNjngRZ+/+veSvm3 uxZA== 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=WxWS/Gdj9HB8+LY4XIChbYX4Fz5bQD6zz9sFEv2H7Lg=; b=IYkJtgt6xTHrzBi5Kz1OZZWBMo3lGf8tj5LU/2udyG3eWO621/TKLbfAnkpn7NBRRV mAtkh2DmJMcq5mw+0tn8mHW0p9tYf+w/6GfPC6UdVs0n2tUIlXkEPM9nVlIaWcYbPh6F zMbGU+x1zyFCWP6SoI8J6iIKz1dvV6VS9uKVGNntwQtKUV3Bl0mtMnsCsGzHABiXrW8t 9a+rHV50X600cFFOx71QmEJpDqmPNJpapvXOWQLRPBl3xP/BcZbGXpo8h0Qjup4QjrzA 2Z4L0aPLN8mbcgFbcy9iLIPhddE9piHk9oQIvqU/eVwv1G/7iMl/UiBQV5kBl3nCiems 07Ig== X-Gm-Message-State: AOAM532WR3y45QFxqm/jbtfszyuCSALZbXfIfDIG+nbB9la9gpY2HR/s Po33Uo29Fgk3JmmZZJW+sNYQBAPVovPmwFEStx7lsQ== X-Received: by 2002:a05:622a:3c8:: with SMTP id k8mr2788365qtx.101.1616470533440; Mon, 22 Mar 2021 20:35:33 -0700 (PDT) MIME-Version: 1.0 References: <20210317045949.1584952-1-joshdon@google.com> <20210317082550.GA3881262@gmail.com> <20210319090252.GF15768@suse.de> In-Reply-To: <20210319090252.GF15768@suse.de> From: Josh Don Date: Mon, 22 Mar 2021 20:35:22 -0700 Message-ID: Subject: Re: [PATCH] sched: Warn on long periods of pending need_resched To: Mel Gorman Cc: Ingo Molnar , Ingo Molnar , Peter Zijlstra , Juri Lelli , Vincent Guittot , Dietmar Eggemann , Steven Rostedt , Ben Segall , Daniel Bristot de Oliveira , Luis Chamberlain , Kees Cook , Iurii Zaikin , linux-kernel , linux-fsdevel@vger.kernel.org, David Rientjes , Oleg Rombakh , Paul Turner Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 19, 2021 at 2:02 AM Mel Gorman wrote: > > Default disabling and hidden behind a static branch would be useful > because the majority of users are not going to know what to do about > a need_resched warning and the sysctl is not documented. As Ingo said, > SCHED_DEBUG is enabled by default a lot. While I'm not sure what motivates > most distributions, I have found it useful to display topology information > on boot and in rare cases, for the enabling/disabling of sched features. > Hence, sched debug features should avoid adding too much overhead where > possible. > > The static branch would mean splitting the very large inline functions > adding by the patch. The inline section should do a static check only and > do the main work in a function in kernel/sched/debug.c so it has minimal > overhead if unused. > > -- > Mel Gorman > SUSE Labs Makes sense, I'll include this in v2. Thanks, Josh