Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp839617ybv; Thu, 20 Feb 2020 08:12:03 -0800 (PST) X-Google-Smtp-Source: APXvYqx4NR8K5EUQnAXdHel3LlALmYfgtBa6l/thHp4DcaNHpsorBLjKvkWr/zyTqoaUsuDJ9iP3 X-Received: by 2002:aca:4994:: with SMTP id w142mr2499579oia.178.1582215123159; Thu, 20 Feb 2020 08:12:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582215123; cv=none; d=google.com; s=arc-20160816; b=aMeNIPnCEORJVPRRQZSBrVrvG0jcni68CbUtJ0wWO+vpcsy95HHnUWU9zHq9roa863 3tv9nhwo9T+YTlRNHkNB4yNg7H/6vZz0rShiBE8regeg+H1RfERVGBlIoFc7HYbj5Oz0 WDYKZMuuzJtO1ENAd909S4frmaZfVsUBS//dUiUX8mKDRBXaA9Xgnf3NsKbTX4unZt+3 144Wh1AuntQvjMEs0cm42yjlAAUhN7jT7DqaRdYocqlDquypdZt5Oc53+cNES1Y+CDVG puwSUKWPIOUZM1A6iKjknCZDaRC4mEAhSsjOR8aC945Bf0J6tNvkNwnhVDhw5Q1zvVHo YK2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=QAPYagKUGqLZKg5ON9Ixm+s9oOOE8yLx7m4JqHcUe84=; b=vfGU1BW2/Ig9AqD0ME8v9hnminApqbCV6dPt5hrDEwidAsv82Xvlleu2BK2S9hM3kn hDE/oBj4jNh/mVucNRV5cgSbFoY7HNF2JLMHhLsGj8EICCfSO1FGLzZEnoKfSiXQsjcR +MurFE9VmWw9PI6g8haqTk94qjlBBVYNoTHk3jb9Aj/28RP23/Bs/b+7iIyzaz5gDGWA qWiXx52owpFNflwM5Y+osoUWoSilM60epFgjLCPgElmJpEuvI9kEJ0ZtcL3yWL/kKvJs WNEKFtzeS6pO+erp6rUaepo2n5rPYilFBAq4OkzdRN0qtAOa1XsOycRc8511c8hpxWb3 xiGg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j1si1842406otn.53.2020.02.20.08.11.44; Thu, 20 Feb 2020 08:12:03 -0800 (PST) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728575AbgBTQLb (ORCPT + 99 others); Thu, 20 Feb 2020 11:11:31 -0500 Received: from foss.arm.com ([217.140.110.172]:45702 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728523AbgBTQLb (ORCPT ); Thu, 20 Feb 2020 11:11:31 -0500 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 216BB31B; Thu, 20 Feb 2020 08:11:31 -0800 (PST) Received: from [10.0.2.15] (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 1B0A73F6CF; Thu, 20 Feb 2020 08:11:28 -0800 (PST) Subject: Re: [PATCH v3 4/5] sched/pelt: Add a new runnable average signal To: Vincent Guittot Cc: Ingo Molnar , Peter Zijlstra , Juri Lelli , Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , linux-kernel , Phil Auld , Parth Shah , Hillf Danton References: <20200214152729.6059-5-vincent.guittot@linaro.org> <20200219125513.8953-1-vincent.guittot@linaro.org> <9fe822fc-c311-2b97-ae14-b9269dd99f1e@arm.com> From: Valentin Schneider Message-ID: Date: Thu, 20 Feb 2020 16:11:18 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 20/02/2020 14:36, Vincent Guittot wrote: > I agree that setting by default to SCHED_CAPACITY_SCALE is too much > for little core. > The problem for little core can be fixed by using the cpu capacity instead > So that's indeed better for big.LITTLE & co. Any reason however for not aligning with the initialization of util_avg ? With the default MC imbalance_pct (117), it takes 875 utilization to make a single CPU group (with 1024 capacity) overloaded (group_is_overloaded()). For a completely idle CPU, that means forking at least 3 tasks (512 + 256 + 128 util_avg) With your change, it only takes 2 tasks. I know I'm being nitpicky here, but I feel like those should be aligned, unless we have a proper argument against it - in which case this should also appear in the changelog with so far only mentions issues with util_avg migration, not the fork time initialization. > @@ -796,6 +794,8 @@ void post_init_entity_util_avg(struct task_struct *p) > } > } > > + sa->runnable_avg = cpu_scale; > + > if (p->sched_class != &fair_sched_class) { > /* > * For !fair tasks do: >> >>> sa->load_avg = scale_load_down(se->load.weight); >>> + } >>> >>> /* when this task enqueue'ed, it will contribute to its cfs_rq's load_avg */ >>> }