Received: by 10.213.65.68 with SMTP id h4csp1496618imn; Thu, 29 Mar 2018 05:55:00 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+WW6M4jahKHsFq7ypadaKXqwfv7WyLAg/wuHsMPu3EzQcXGac/y4bqaV6X1AM+FIWcPDB7 X-Received: by 2002:a17:902:8c94:: with SMTP id t20-v6mr8233403plo.95.1522328100122; Thu, 29 Mar 2018 05:55:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522328100; cv=none; d=google.com; s=arc-20160816; b=OHmtaBA88BoujG189Ft5mPvjWV+QSbqwqy8asBgpwq1MV0NBBdkCf8OnntJLr03Q3V 7U2DuyW60SuQ7WSMxlamtR1752PBlwA6A0NiOaJpg1wlVY1SvAEJi6/2bQ2TsB4IOMBJ UCn1LEI385lM2Tkl4g1PmsfSrCv2Eo6OI5zI8+gMle+Wi+Vc8YhwdUopfoL/xWiU44rS SN9rZXg40ZqaLeTjTBAyOfOx1qBFxOwnEO/rUpICRrZqQq84M5IRbJP7WjoqC0NGmnBe WqDxoHWotUVWgA12H5y8iQ6YZwtW6GBa8jHnXoEuFaLsBeqJ/HHMQNVQcK61UARzCccd doPA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=TQvGEvdYmLG4pkNdWzsGZCDXRzv0GWvQI9JZHFmuiGA=; b=Re308fmbssbRehsBitnPEuJVC3wsCdvGlmXESbB4w/wZNC0GaOqlK5ENDIabNdRQq7 4YfMeyE8tSsZ3azPWT1jbcsd2t0pNmJO317cAIohjnbPbEWvqzLsxiH4h31qCcIF8axl miWLW72yXhFiJRXd1uJ3LJeNIrmCE7Po9PZRl3qIN5jxGUR1LITxSC8/gpoin3h0W2Ob zyyuHV7YlqCgP3hvG7KD0yHZGv7WgJCed4w5VaExPBpnL1K7n3FtIpAA5ZYUoh/0oEcT DCoBiXNo3OuJlj0P7lCNtv5ry5BFp9vURFxNZr2dyBOSqtCHWw+lPkNc9h6DcCx4XthK H35A== 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 a68si4511933pfk.35.2018.03.29.05.54.46; Thu, 29 Mar 2018 05:55:00 -0700 (PDT) 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 S1752543AbeC2Mxa (ORCPT + 99 others); Thu, 29 Mar 2018 08:53:30 -0400 Received: from foss.arm.com ([217.140.101.70]:54326 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752067AbeC2Mx3 (ORCPT ); Thu, 29 Mar 2018 08:53:29 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id B24C81529; Thu, 29 Mar 2018 05:53:28 -0700 (PDT) Received: from e105550-lin.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.72.51.249]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 3A26C3F590; Thu, 29 Mar 2018 05:53:27 -0700 (PDT) Date: Thu, 29 Mar 2018 13:53:24 +0100 From: Morten Rasmussen To: Vincent Guittot Cc: catalin.marinas@arm.com, will.deacon@arm.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, peterz@infradead.org, dietmar.eggemann@arm.com, chris.redpath@arm.com Subject: Re: [PATCH] sched: support dynamiQ cluster Message-ID: <20180329125324.GR4589@e105550-lin.cambridge.arm.com> References: <1522223215-23524-1-git-send-email-vincent.guittot@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1522223215-23524-1-git-send-email-vincent.guittot@linaro.org> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 28, 2018 at 09:46:55AM +0200, Vincent Guittot wrote: > Arm DynamiQ system can integrate cores with different micro architecture > or max OPP under the same DSU so we can have cores with different compute > capacity at the LLC (which was not the case with legacy big/LITTLE > architecture). Such configuration is similar in some way to ITMT on intel > platform which allows some cores to be boosted to higher turbo frequency > than others and which uses SD_ASYM_PACKING feature to ensures that CPUs with > highest capacity, will always be used in priortiy in order to provide > maximum throughput. > > Add arch_asym_cpu_priority() for arm64 as this function is used to > differentiate CPUs in the scheduler. The CPU's capacity is used to order > CPUs in the same DSU. > > Create sched domain topolgy level for arm64 so we can set SD_ASYM_PACKING > at MC level. > > Some tests have been done on a hikey960 platform (quad cortex-A53, > quad cortex-A73). For the test purpose, the CPUs topology of the hikey960 > has been modified so the 8 heterogeneous cores are described as being part > of the same cluster and sharing resources (MC level) like with a DynamiQ DSU. > > Results below show the time in seconds to run sysbench --test=cpu with an > increasing number of threads. The sysbench test run 32 times > > without patch with patch diff > 1 threads 11.04(+/- 30%) 8.86(+/- 0%) -19% > 2 threads 5.59(+/- 14%) 4.43(+/- 0%) -20% > 3 threads 3.80(+/- 13%) 2.95(+/- 0%) -22% > 4 threads 3.10(+/- 12%) 2.22(+/- 0%) -28% > 5 threads 2.47(+/- 5%) 1.95(+/- 0%) -21% > 6 threads 2.09(+/- 0%) 1.73(+/- 0%) -17% > 7 threads 1.64(+/- 0%) 1.56(+/- 0%) - 7% > 8 threads 1.42(+/- 0%) 1.42(+/- 0%) 0% > > Results show a better and stable results across iteration with the patch > compared to mainline because we are always using big cores in priority whereas > with mainline, the scheduler randomly choose a big or a little cores when > there are more cores than number of threads. > With 1 thread, the test duration varies in the range [8.85 .. 15.86] for > mainline whereas it stays in the range [8.85..8.87] with the patch Using ASYM_PACKING is essentially an easier but somewhat less accurate way to achieve the same behaviour for big.LITTLE system as with the "misfit task" series that been under review here for the last couple of months. As I see it, the main differences is that ASYM_PACKING attempts to pack all tasks regardless of task utilization on the higher capacity cpus whereas the "misfit task" series carefully picks cpus with tasks they can't handle so we don't risk migrating tasks which are perfectly suitable to for a little cpu to a big cpu unnecessarily. Also it is based directly on utilization and cpu capacity like the capacity awareness we already have to deal with big.LITTLE in the wake-up path. Furthermore, it should work for all big.LITTLE systems regardless of the topology, where I think ASYM_PACKING might not work well for systems with separate big and little sched_domains. Have to tried taking the misfit patches for a spin on your setup? I expect them give you the same behaviour as you report above. Morten