Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp5834563rdb; Thu, 14 Dec 2023 00:18:28 -0800 (PST) X-Google-Smtp-Source: AGHT+IFJvMLLW4VEtpuJVrXAlKVHZeT29qJOCs0PDryZaQk1D3uHdZJy40rfHZJDzNyVEY7LtYak X-Received: by 2002:a17:903:32c7:b0:1d3:6110:32fd with SMTP id i7-20020a17090332c700b001d3611032fdmr994195plr.110.1702541908550; Thu, 14 Dec 2023 00:18:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702541908; cv=none; d=google.com; s=arc-20160816; b=OLRjBzYFlC0zebgMuQfciwmDLcBxJ7WpjjArtbVwkMYfTqEzfuaChGv+d6NxqFdLV+ T9QLQ46PjQbeMk1OASOJysdD3lEUakbJM+5HEQP2ENVMzlD+iSyi4oN1HITGuBfL56+x VZNyw7Jj8CjT0t9TgO/B3RzkJEf1lCArk4SrPpy+Ka43O/OkVVpKS893A9T01OjF3Pxb WHLqzw1aGiOu3O2QoYgo8PBPJW4TrN/tj+h5FlDkfyUbCrFXux74Ti8CgePiZzPiCYrF WLb8Dn3H7+RbhNbIXFClb4LC06P0VWXkwSAC1p2exeK7r1vM3A9tPUmGSQ2/qLIcwNvt ISuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id; bh=nEiN8e89AxruCOBaMQ8RlUUg1kPwUUFAuh/5W7zXvuY=; fh=siXXS4fiKM+UN3XvISWlFHzUucsvWdSox+YvKT1j0bs=; b=aZ8C5pQllS4Mp4IifTbdkZxw/nSs11X/L6AIbYE4NoLIpRhbPkpKUGeya9CuefRIkl e7FBxodBXI58yWFBHpYImhfJ+70jxhh2ePbfZYADtkhBgY1sAiUiQzjYItFb/qc2syt/ D72wgPqOf1SAl1rw3J/YwS5ULOZDEZlP9BOFE7iy0N9bFpDgYejNqG7N4u0Ledx1qaBz WCzAn0mohxH7NFyvd33CT4Y5K7P5ScX5rD+r/24PonGE89gBQ3tg/simND3piu7Ew3gU b+iwWc1tbTCRHJ8r0ePAU9tQxFRHu2GgYaSNClKmvXltUhuOzvv0GuiRdG+3hzXTDREE c12A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id j14-20020a170903024e00b001d1ce46f067si11087174plh.485.2023.12.14.00.18.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 14 Dec 2023 00:18:28 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 278F680F6D23; Thu, 14 Dec 2023 00:18:26 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230064AbjLNISL (ORCPT + 99 others); Thu, 14 Dec 2023 03:18:11 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48382 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229731AbjLNISJ (ORCPT ); Thu, 14 Dec 2023 03:18:09 -0500 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id BB847F5; Thu, 14 Dec 2023 00:18:15 -0800 (PST) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id BEFC1C15; Thu, 14 Dec 2023 00:19:00 -0800 (PST) Received: from [10.57.85.242] (unknown [10.57.85.242]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id E4A303F5A1; Thu, 14 Dec 2023 00:18:12 -0800 (PST) Message-ID: <777b1258-eae2-4f57-9abc-326d1c456c47@arm.com> Date: Thu, 14 Dec 2023 08:19:15 +0000 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 1/4] sched/fair: Be less aggressive in calling cpufreq_update_util() Content-Language: en-US To: Qais Yousef Cc: linux-kernel@vger.kernel.org, Vincent Guittot , Viresh Kumar , "Rafael J. Wysocki" , Dietmar Eggemann , linux-pm@vger.kernel.org, Ingo Molnar , Wei Wang , Rick Yiu , Chung-Kai Mei , Hongyan Xia , Peter Zijlstra References: <20231208015242.385103-1-qyousef@layalina.io> <20231208015242.385103-2-qyousef@layalina.io> <20231210205156.kausxdcwsydggwie@airbuntu> <8ee6425a-0a0e-4391-9fd3-8fe74c809772@arm.com> <20231212121023.mehtligcuwcmjtz4@airbuntu> From: Lukasz Luba In-Reply-To: <20231212121023.mehtligcuwcmjtz4@airbuntu> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Thu, 14 Dec 2023 00:18:26 -0800 (PST) On 12/12/23 12:10, Qais Yousef wrote: > On 12/11/23 07:56, Lukasz Luba wrote: >> >> >> On 12/10/23 20:51, Qais Yousef wrote: >>> On 12/08/23 10:05, Lukasz Luba wrote: >>>> Hi Qais, >>>> >>>> On 12/8/23 01:52, Qais Yousef wrote: >>>> >>>> [snip] >>>> >>>>> @@ -6704,14 +6677,6 @@ enqueue_task_fair(struct rq *rq, struct task_struct *p, int flags) >>>>> */ >>>>> util_est_enqueue(&rq->cfs, p); >>>>> - /* >>>>> - * If in_iowait is set, the code below may not trigger any cpufreq >>>>> - * utilization updates, so do it here explicitly with the IOWAIT flag >>>>> - * passed. >>>>> - */ >>>>> - if (p->in_iowait) >>>>> - cpufreq_update_util(rq, SCHED_CPUFREQ_IOWAIT); >>>>> - >>>> >>>> Why this io wait boost is considered as the $subject says 'aggressive' >>>> calling? >>> >>> This will trigger a frequency update along with the iowait boost. Did I miss >>> something? >> >> Yes, it will change CPU freq and it was the main goal for this code >> path. We have tests which check how that works on different memory >> types. >> >> Why do you want to remove it? > > It seems you missed this hunk? I of course didn't remove it altogether if > that's what you mean :) > > @@ -6772,6 +6737,8 @@ enqueue_task_fair(struct rq *rq, struct task_struct *p, int flags) > enqueue_throttle: > assert_list_leaf_cfs_rq(rq); > > + cpufreq_update_util(rq, p->in_iowait ? SCHED_CPUFREQ_IOWAIT : 0); > + > hrtick_update(rq); > } > Yes, you're right, I missed that change. I will have to spend some time to figure out this new flow in the whole patch set. >> >> Did you run some tests (e.g. fio, gallery, etc) to check if you still >> have a decent performance out some new ufs/nvme memories? > > PCMark storage gives > > before*: 29681 > after: 30014 The result looks good. Thanks, Lukasz