From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754564AbdESPAk (ORCPT ); Fri, 19 May 2017 11:00:40 -0400 Received: from mail-pf0-f178.google.com ([209.85.192.178]:35922 "EHLO mail-pf0-f178.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750783AbdESPAj (ORCPT ); Fri, 19 May 2017 11:00:39 -0400 Date: Fri, 19 May 2017 16:00:35 +0100 From: Matt Fleming To: Peter Zijlstra Cc: mingo@kernel.org, tglx@linutronix.de, riel@redhat.com, hpa@zytor.com, efault@gmx.de, linux-kernel@vger.kernel.org, torvalds@linux-foundation.org, lvenanci@redhat.com, xiaolong.ye@intel.com, kitsunyan@inbox.ru, clm@fb.com Subject: Re: hackbench vs select_idle_sibling; was: [tip:sched/core] sched/fair, cpumask: Export for_each_cpu_wrap() Message-ID: <20170519150035.GA2879@codeblueprint.co.uk> References: <20170414122005.o35me2h5nowqkxbv@hirez.programming.kicks-ass.net> <20170517105350.hk5m4h4jb6dfr65a@hirez.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170517105350.hk5m4h4jb6dfr65a@hirez.programming.kicks-ass.net> User-Agent: Mutt/1.5.24+41 (02bc14ed1569) (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 17 May, at 12:53:50PM, Peter Zijlstra wrote: > > Please test.. Results are still coming in but things do look better with your patch applied. It does look like there's a regression when running hackbench in process mode and when the CPUs are not fully utilised, e.g. check this out: hackbench-process-pipes 4.4.68 4.4.68 4.4.68 4.4.68 sles12-sp3 select-idle-cpu-aggressive for-each-cpu-wrap-fix latest-hackbench-fix Amean 1 0.8853 ( 0.00%) 1.2160 (-37.35%) 1.0350 (-16.91%) 1.1853 (-33.89%) This machine has 80 CPUs and that's a 40 process workload. Here's the key: select-idle-cpu-aggressive: 4c77b18cf8b7 ("sched/fair: Make select_idle_cpu() more aggressive") for-each-cpu-wrap-fix: c743f0a5c50f ("sched/fair, cpumask: Export for_each_cpu_wrap()") latest-hackbench-fix: this patch But those results definitely look to be an exception. Here's the same machine running the same number of tasks but with pthreads, hackbench-thread-pipes 4.4.68 4.4.68 4.4.68 4.4.68 sles12-sp3 select-idle-cpu-aggressive for-each-cpu-wrap-fix latest-hackbench-fix Amean 1 0.7427 ( 0.00%) 0.9760 (-31.42%) 1.1907 (-60.32%) 0.7643 ( -2.92%) Nice win.