Received: by 2002:a05:6a10:a852:0:0:0:0 with SMTP id d18csp3545954pxy; Tue, 4 May 2021 04:53:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwl7bEm75uYs0ViMkN/2CcbpiPiTWFNyPruwYW4CK6xYfPSupVwJKQFTl9yhoLqsga1gVOz X-Received: by 2002:a63:cd11:: with SMTP id i17mr22658344pgg.74.1620129217348; Tue, 04 May 2021 04:53:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620129217; cv=none; d=google.com; s=arc-20160816; b=mZpuFYW2xz0NPND+drcFW/b2qGrP8FIcy3jqTkq2iG4GLcLdmPa8t9BV0fHGoKNuxN Gp2TroutyoGliFUNucenI/WPvz3C7fMCnSWWMvAE6GJmekiySekKlWGfHn5fMqVHaI1r Ts19+q+PasFuQJX3suX2XFi5AbeMoujJ3/UsGo9eJLRKOxmzreg5CmVM9c6EOcp0fvZZ nD03iSHcd95raifIREtv16/vWFhA2GEns7YurZ/1W3Fjjjccie5bUeajOhXCQ6jcZ2UR UxXYuj0cdKVsJF9oLYMWFTxzxYGqblM9LbSThVRJxb72tqZmJvOR0v4ciNGsbyA+CY8W Usag== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=Ojk0uBlcSQA0tRoIr6v61EVqnolFhG0EuiHG8D7GLow=; b=kTFZ6O0oT/05TAzpIFtQQB/yMqX8iz5WodLKhHfb/eWigskEzR6/RUOU7xsvFt2lJG T+vyd9kHSaG3mFDIAtgKn1TIV3Rs/zu3rdJyHoekpyf2kSTyf7WnNK+chDvkmqCPbV5m 5Z6lpcRnyuY25upqqSp9Xo5Dv/To0rSPiNpSdyasypMxsv9Icfv9VYDs0RAYpv3j0Kb4 SehnnTLin/jPg9rCbKqTjdn9RryHkobsfyer6q8bmVARseXIm7ExOuYJ4sZ3gnFsMEzZ 3foK3NzkUz3EosFXaspMgbwWqpr4g6WxNhh9SGi/suSIUhPCeV6Wip+QKyckuWOjKKFb Rfhw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=KRpkSYzo; 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=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id gb19si16369228pjb.57.2021.05.04.04.53.25; Tue, 04 May 2021 04:53:37 -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=@gmail.com header.s=20161025 header.b=KRpkSYzo; 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=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230245AbhEDLuq (ORCPT + 99 others); Tue, 4 May 2021 07:50:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50800 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230089AbhEDLup (ORCPT ); Tue, 4 May 2021 07:50:45 -0400 Received: from mail-lj1-x22a.google.com (mail-lj1-x22a.google.com [IPv6:2a00:1450:4864:20::22a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DAC29C061574 for ; Tue, 4 May 2021 04:49:49 -0700 (PDT) Received: by mail-lj1-x22a.google.com with SMTP id y9so5726364ljn.6 for ; Tue, 04 May 2021 04:49:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=Ojk0uBlcSQA0tRoIr6v61EVqnolFhG0EuiHG8D7GLow=; b=KRpkSYzoZGwaGRkN1Ey+Rwmni9zy8TzJkmZmJlhT50ctyokurFobZoDpzNdvR9utBz 6edivwHlBmDU9f2ra+TjMK49Jno1YE67rkr1P/ynF50TEx970UsvxhLJyqN0LYcpegoX tY4A1zehnbDfzQ1Gev+bbHwDiBW/oxeyHCdr0MxvVKM17vGTqP0+XRYSrNWnEa7f9ydW Z+MNQZOEf1FWMdnue7sJo5hZVAlDIgZ2jW2TmnYpQu0M0yHFe7l8/gE3ipoBP8ZWW+Ia ETAbUmmqWSl8m0rWlGJnAolXBSsXK1UZUwmVAI7ySiyQZGhKpB3nuQjK0c2eVBVEp6l0 N+4Q== 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:content-transfer-encoding; bh=Ojk0uBlcSQA0tRoIr6v61EVqnolFhG0EuiHG8D7GLow=; b=PgYCZvZ6fwAxB2ufjsso7hcm/usd8j/EuUieTEM4tOQPcUXN0ImPmXZGuribCSWdbc DeF03Law9cxOCmhrmTR+EwXATwxR3lttOiQmLqjnFKHXyhYV3tLpd4c3bL29zlGEPTeV Gbd5kYfCaGYwBtux1nyOrH/MC8hemZT7urWi6Rht/FHAzx/nP9gVGP8xfJ88XJhMN7RT Ay79nKsc3YrV4gw6QIgsNI6MZb/2FdbErwg2uuTypJ0QJglClMEHyJFd5sTQgGFQLL+I YY07fkBRPZ8XsLNYByfs3MHZL4JK73SSUi+MGisC8qezASGao7GIjvLXU7D/G6wTt2ky eBHg== X-Gm-Message-State: AOAM531z9SqR+yQta3RrSqz06GwPg+EZSNcQnrGDMTrpxl6gYanowe1S nfztW5FS59lb4783w4iaIASoycygVct5DnhXRwc= X-Received: by 2002:a2e:b88b:: with SMTP id r11mr17094355ljp.227.1620128988341; Tue, 04 May 2021 04:49:48 -0700 (PDT) MIME-Version: 1.0 References: <20210504090743.9688-1-Pierre.Gondois@arm.com> In-Reply-To: From: Xuewen Yan Date: Tue, 4 May 2021 19:49:29 +0800 Message-ID: Subject: Re: [PATCH v3 0/2] sched/fair: find_energy_efficient_cpu() enhancements To: Pierre Gondois Cc: linux-kernel , Xuewen Yan , qperret@qperret.net, Lukasz.Luba@arm.com, Dietmar Eggemann , Vincent.Donnefort@arm.com, Ingo Molnar , Peter Zijlstra , Juri Lelli , Vincent Guittot , Steven Rostedt , Benjamin Segall , Mel Gorman , Daniel Bristot de Oliveira Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Pierre=EF=BC=8C The two patches look good to me. Thanks Xuewen Yan On Tue, May 4, 2021 at 5:11 PM Pierre Gondois wrot= e: > > Hi Xuewen, > > Please let me know if you have some comments, > Pierre > > On 5/4/21 10:07 AM, Pierre Gondois wrote: > > V2: > > - Split the patch in 2. [Quentin] > > - Add testing results to the cover-letter. [Dietmar] > > - Put back 'rcu_read_unlock()' to unlock the rcu > > earlier. [Dietmar] > > - Various comments. [Dietmar/Quentin] > > > > V3: > > - Layout/phrasing. [Dietmar] > > > > This patchset prevents underflows in find_energy_efficient_cpu(). > > This is done in the second patch: > > sched/fair: Fix negative energy delta in find_energy_efficient_cpu() > > > > The first patch: > > sched/fair: Only compute base_energy_pd if necessary > > prevents an unnecessary call to compute_energy() if no CPU is available > > in a performance domain (pd). > > When looping over the pds, it also allows to gather the calls > > to compute_energy(), reducing the chances of having utilization signals > > being concurrently updated and having a 'negative delta'. > > > > The energy tests of the initial EAS enablement at: > > https://lkml.kernel.org/r/20181203095628.11858-1-quentin.perret@arm.com > > have been executed using LISA on a Juno-r2 (2xA57 + 4xA53). > > > > To recall the test: > > "10 iterations of between 10 and 50 periodic rt-app tasks (16ms period, > > 5% duty-cycle) for 30 seconds with energy measurement. Unit is Joules. > > The goal is to save energy, so lower is better." > > "Energy is measured with the onboard energy meter. Numbers include > > consumption of big and little CPUs." > > > > +----------+-----------------+-------------------------+ > > | | Without patches | With patches | > > +----------+--------+--------+------------------+------+ > > | Tasks nb | Mean | CI* | Mean | CI* | > > +----------+--------+--------+------------------+------+ > > | 10 | 6.57 | 0.24 | 6.46 (-1.63%) | 0.27 | > > | 20 | 12.44 | 0.21 | 12.44 (-0.01%) | 0.14 | > > | 30 | 19.10 | 0.78 | 18.75 (-1.85%) | 0.15 | > > | 40 | 27.27 | 0.53 | 27.35 (+0.31%) | 0.33 | > > | 50 | 36.55 | 0.42 | 36.28 (-0.74%) | 0.42 | > > +----------+-----------------+-------------------------+ > > CI: confidence interval > > > > For each line, the intervals of values w/ w/o the patches are > > overlapping (consider Mean +/- CI). Thus, the energy results shouldn't > > have been impacted. > > > > Pierre Gondois (2): > > sched/fair: Only compute base_energy_pd if necessary > > sched/fair: Fix negative energy delta in find_energy_efficient_cpu() > > > > kernel/sched/fair.c | 68 ++++++++++++++++++++++++++------------------= - > > 1 file changed, 39 insertions(+), 29 deletions(-) > >