Received: by 2002:a05:6358:700f:b0:131:369:b2a3 with SMTP id 15csp86748rwo; Tue, 1 Aug 2023 13:23:25 -0700 (PDT) X-Google-Smtp-Source: APBJJlEXn4R79VJcIOXzcffnH4zJZhm18gjPzpFsNQFigA2oHQFRxZy9BhZr4888ws5mH0uoVtRV X-Received: by 2002:a05:6a20:3944:b0:127:3fea:500a with SMTP id r4-20020a056a20394400b001273fea500amr14840915pzg.27.1690921405365; Tue, 01 Aug 2023 13:23:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690921405; cv=none; d=google.com; s=arc-20160816; b=n3oRS/67YA6hlAM0YkdsiJhj1dn/crhdchg5V1qT8Ad+tSG6Z7rBcinUXT//9nOn9q 3qt023teeJ8NWAJhp6/GkvtpmUwdtj/N8rak2YOTtO+BpHJGomhBJldPVaHMPMuGVWfl CeT1G2FDJbCdiEcTbVkFFh0NSkZY9me5Pi/LtUz6tK2GU/AHFeAQdcT126XGSqcMP3ya anDbqTkHIFPWVMcC/UMmTs4FfvZcSkRdq+9m9Mzys/kNf9x91M7a9mIsuyLZSyC0GrJ1 xS3oLsJZBCCp86eAB0SHciSeNIJt6qqsz0g1EkZcFX3+oJKd931q5Hbu1TNah4EM69Q/ ew9A== 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=Qw60mH27Vw82wQWnmWQuEGPBWj63KnGH7uHbL6UntqE=; fh=Af0TSsBJ/1V9PzWEqlGZQbe4W93rH3tFDb8nZ2DwyAk=; b=VZkdOaKk3enoAr2n21iShT45PGF/L8Y6mMI00A265mTfBiK3h6+fLfaF1b4cl4Y3vi NQx2x0GMEMXXLSkf+iSVksavKCQQtkY2g4XZqQcNLyYNzdDXmdrW9hlVmbgayo6tVkgE u+f8eHVz30Z+L1BNi20f40Ca5vp3CAEoA+8iqTw+BVGQNJUC/SIdPA2zwH0uITLkqrS7 y8aIRnq8VgHcAceO/AbTCP4BxWW0p6wPGRbQFpM3h/xexrrbUz0Ia/uVb6xb5UQh0+oy ueLRw+Ltj8pfAkwjkB+SlBipDwCnoyL3opGtthkDKkiByvyYxl29yb1yHdQK9CpJodOB iU7g== 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ei20-20020a056a0080d400b006738dfbaf42si9353957pfb.374.2023.08.01.13.23.11; Tue, 01 Aug 2023 13:23:25 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232565AbjHATlT (ORCPT + 99 others); Tue, 1 Aug 2023 15:41:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32904 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229880AbjHATlQ (ORCPT ); Tue, 1 Aug 2023 15:41:16 -0400 Received: from cloudserver094114.home.pl (cloudserver094114.home.pl [79.96.170.134]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9C4F61FF3; Tue, 1 Aug 2023 12:41:14 -0700 (PDT) Received: from localhost (127.0.0.1) (HELO v370.home.net.pl) by /usr/run/smtp (/usr/run/postfix/private/idea_relay_lmtp) via UNIX with SMTP (IdeaSmtpServer 5.2.0) id 9a48f1ec80921127; Tue, 1 Aug 2023 21:41:12 +0200 Authentication-Results: v370.home.net.pl; spf=softfail (domain owner discourages use of this host) smtp.mailfrom=rjwysocki.net (client-ip=195.136.19.94; helo=[195.136.19.94]; envelope-from=rjw@rjwysocki.net; receiver=) Received: from kreacher.localnet (unknown [195.136.19.94]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by v370.home.net.pl (Postfix) with ESMTPSA id 365E16621DD; Tue, 1 Aug 2023 21:41:12 +0200 (CEST) From: "Rafael J. Wysocki" To: Linux PM , Peter Zijlstra , Anna-Maria Behnsen Cc: LKML , Frederic Weisbecker , Kajetan Puchalski Subject: [RFC/RFT][PATCH v1 0/2] cpuidle: teo: Do not check timers unconditionally every time Date: Tue, 01 Aug 2023 21:35:15 +0200 Message-ID: <4511619.LvFx2qVVIh@kreacher> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="UTF-8" X-CLIENT-IP: 195.136.19.94 X-CLIENT-HOSTNAME: 195.136.19.94 X-VADE-SPAMSTATE: clean X-VADE-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedviedrjeeigddufeeiucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecujffqoffgrffnpdggtffipffknecuuegrihhlohhuthemucduhedtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefhvfevufffkfgggfgtsehtufertddttdejnecuhfhrohhmpedftfgrfhgrvghlucflrdcuhgihshhotghkihdfuceorhhjfiesrhhjfiihshhotghkihdrnhgvtheqnecuggftrfgrthhtvghrnhepgeffhfdujeelhfdtgeffkeetudfhtefhhfeiteethfekvefgvdfgfeeikeeigfehnecuffhomhgrihhnpehkvghrnhgvlhdrohhrghenucfkphepudelhedrudefiedrudelrdelgeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepihhnvghtpeduleehrddufeeirdduledrleegpdhhvghlohepkhhrvggrtghhvghrrdhlohgtrghlnhgvthdpmhgrihhlfhhrohhmpedftfgrfhgrvghlucflrdcuhgihshhotghkihdfuceorhhjfiesrhhjfiihshhotghkihdrnhgvtheqpdhnsggprhgtphhtthhopeeipdhrtghpthhtoheplhhinhhugidqphhmsehvghgvrhdrkhgvrhhnvghlrdhorhhgpdhrtghpthhtohepphgvthgvrhiisehinhhfrhgruggvrggurdhorhhgpdhrtghpthhtoheprghnnhgrqdhmrghrihgrsehlihhnuhhtrhhonhhigidruggvpdhrtghpthhtoheplhhinhhugidqkhgvrhhnvghlsehvghgvrhdrkhgvrhhn vghlrdhorhhgpdhrtghpthhtohepfhhrvgguvghrihgtsehkvghrnhgvlhdrohhrghdprhgtphhtthhopehkrghjvghtrghnrdhpuhgthhgrlhhskhhisegrrhhmrdgtohhm X-DCC--Metrics: v370.home.net.pl 1024; Body=6 Fuz1=6 Fuz2=6 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_BLOCKED,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 Hi Folks, This is on top of the fixes series posted previously: https://lore.kernel.org/linux-pm/4515817.LvFx2qVVIh@kreacher/ (I'll put it all into one git branch tomorrow). I started to play with the idea described here https://lore.kernel.org/linux-pm/CAJZ5v0hQh2Pg_uXxj8KBRw3oLS1WdsU+rUafBAAq7dRdbRwYSA@mail.gmail.com/ and this is the result. Note that this is completely experimental, even though it doesn't kill any of the test boxes I've run it on. Patch [1/2] moves the tick_nohz_get_sleep_length() call in teo_select() after a preliminary idle state selection based on statistics and patch [2/2] adds checks to avoid it completely if the idle state selected so far is shallow enough. I would appreciate checking if this actually makes any difference. Thanks!