[tip:,sched/core] sched/fair: Do strict inequality check for busiest misfit task group
Message ID | 170915760926.398.7923117841020138205.tip-bot2@tip-bot2 |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-85757-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:6358:a1a:b0:17b:cd04:e0c6 with SMTP id 26csp218755rwa; Wed, 28 Feb 2024 14:02:29 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCUTkdB9qUeMDL2TIrJD4EVC3+AKG25EJqESnWLi35vSqkvdtnFjyRfmknZJtlBVt4KPlcLnY65Zuj2nNZx6B7Sg7BQgHA== X-Google-Smtp-Source: AGHT+IF9Fli4/6HvNIZnyAOTbM3ICMC+J0tGMkP4naTYS6UEGRf0kNYyO98lSY2eYxVrqMv9V95q X-Received: by 2002:a17:90a:d484:b0:29b:5c2:76ac with SMTP id s4-20020a17090ad48400b0029b05c276acmr492352pju.5.1709157749353; Wed, 28 Feb 2024 14:02:29 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709157749; cv=pass; d=google.com; s=arc-20160816; b=Hmf0HtTB941AOl/vlFrO7QkrlPS/h+os+ITbWLobt633+GAp0fESZy4nMxjBeZzBI5 ePBxCEF4bYSkayHgzyInZ2f1omvIEJxmLNBm7UgOkL+V3JGaHqG44lFaWVA6kxZJIeqY pL5S1xlSa8WY9+F6ETktEX1hg3C2dm5LdfEVerbsKncSBJjP8hQec0McdOM8yR++INDV axbfH/qWCjYu81WvaEphI0l5T/dxhZ9418ofrVPjzVgfLbaNcnu5BpM8+CmH1RitHy6i yAte7rUpmj289VR4szLVUy+F25Jwuljql3M9PQ96YbYBLYtxbDtgBYNkUJoXfBe5UcuK kvrA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:precedence:robot-unsubscribe:robot-id :message-id:mime-version:list-unsubscribe:list-subscribe:list-id :precedence:references:in-reply-to:cc:subject:to:reply-to:sender :from:dkim-signature:dkim-signature:date; bh=3SA4r/Gx3AtSlXeawLQ8OLlk/NKfZsBIGDG7j0d/YTE=; fh=aKsKE5fLBw4tya2d2+dn+6dU3ZzlKFdKa4YkHd3HkLY=; b=SuVjSiRqxUePPlKHntpind84xJ8Z9klVcDnFtVsN7u6aRaizEhOFPh+Xd58sF5tBlH 1yIy2GpnGGClqjSqD4mmZbVfLti8ZUeZ5uZuY1rZJ2nhKSvqqUiB59HY1AiZSoo4e5YF nGtZahqpeuLjzLdIrcoVRtrsRd4fmMj0ZGmVNwkVIF9N0A+Fn5SUlvGIMePDWtWrfLMx tebSsoiZ4t3Uh41syX64Kfol4Y7Ctjr1NcG0RthwyBzjcvrZY8D6LkL03v3H5X/ZMWqR rmPjuXIfwmfLRF3RQ+odiJXw3pxfzBLEPLnogtZdED8c3zAbTtP1VI8GAuezWjZpZDz6 MBBQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=iYUTMa5G; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; arc=pass (i=1 spf=pass spfdomain=linutronix.de dkim=pass dkdomain=linutronix.de dmarc=pass fromdomain=linutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-85757-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-85757-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id nv5-20020a17090b1b4500b0029ad6562878si80118pjb.52.2024.02.28.14.02.29 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Feb 2024 14:02:29 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-85757-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=iYUTMa5G; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; arc=pass (i=1 spf=pass spfdomain=linutronix.de dkim=pass dkdomain=linutronix.de dmarc=pass fromdomain=linutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-85757-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-85757-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 50C092874BD for <ouuuleilei@gmail.com>; Wed, 28 Feb 2024 22:02:26 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6CD82161B56; Wed, 28 Feb 2024 22:00:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="iYUTMa5G"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="5SHvrTi6" Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0EEB572927; Wed, 28 Feb 2024 22:00:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709157619; cv=none; b=Qr/T0UhMXi3/E44fpRl6l5K0TJ8HYobtZGK3XuDnSVxW/pAopbTdySb2FjMn5E9apLaigwNhmVCXAp6mTqg9DkpZxc37MUfw/KO4r8SB2UsUHHKQQnP/GHvz2M2yrxZCHWULzES706NVE9w/lEJm4r/5xpdVch8Ibn3/h+dxuKY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709157619; c=relaxed/simple; bh=D4dsBE9SNfENmZbQssQYh+CbA2Sd3b8W99GldeI0y3E=; h=Date:From:To:Subject:Cc:In-Reply-To:References:MIME-Version: Message-ID:Content-Type; b=oO9LP3u4+zRfJ2sR34KebsW3KyLds0enMH6RUivHphRYe27TRKJiKqcG6mmVxZk5Uui+fAqnhBfo6E2M4rmC6mHrQt0zki3loTczLKleB9g50rtl2Grq/RyT0QxQTQsyLSCj8hu/dlq/ExWkLP32pzeVEOO+NOiieEXfAmkBfNg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=iYUTMa5G; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=5SHvrTi6; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de Date: Wed, 28 Feb 2024 22:00:09 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1709157610; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=3SA4r/Gx3AtSlXeawLQ8OLlk/NKfZsBIGDG7j0d/YTE=; b=iYUTMa5GhuXF0NZAxuDK1eTDWvLkp+JvRxM2AOGOzX3smBHXgKZojaAnaVTdhugH0Pns6Y BiG684VT+0N0tR1X2KDarPxJzPFfOmcuImoCCPX0Qa2LdKbxQ5406XmArp4p4xOrohOQbe TvUC5eaf0BcX7q7HXhonc4hWz4U0NSJ/VFtjW73DExg90gZaKLSYJIlO1GkcxuVszox3UU B9zdOVQd+kqaVOR5z6T1gxslgnJvSFrj7olX4ohs7Us/rxbFgrXgFDSo9PaEkt2pmpWBvA 6ruG+PBK3JZdAF39n2rpWcUvLTPr+DeA34wFRbYd9PcxK/ei08Ho2E9FkTCY0A== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1709157610; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=3SA4r/Gx3AtSlXeawLQ8OLlk/NKfZsBIGDG7j0d/YTE=; b=5SHvrTi6gVT82g2SGy4dGDUcRDYdKnJ26RJnm0qJ3iGdwndCA+zKi5fP//2vTUoaY+xpFt CDGT/6IHdE2HPTDw== From: "tip-bot2 for David Vernet" <tip-bot2@linutronix.de> Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: sched/core] sched/fair: Do strict inequality check for busiest misfit task group Cc: David Vernet <void@manifault.com>, Ingo Molnar <mingo@kernel.org>, Vincent Guittot <vincent.guittot@linaro.org>, Valentin Schneider <vschneid@redhat.com>, x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20240206043921.850302-3-void@manifault.com> References: <20240206043921.850302-3-void@manifault.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Message-ID: <170915760926.398.7923117841020138205.tip-bot2@tip-bot2> Robot-ID: <tip-bot2@linutronix.de> Robot-Unsubscribe: Contact <mailto:tglx@linutronix.de> to get blacklisted from these emails Precedence: bulk Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790123089375250109 X-GMAIL-MSGID: 1792181796371985302 |
Series |
[tip:,sched/core] sched/fair: Do strict inequality check for busiest misfit task group
|
|
Commit Message
tip-bot2 for Thomas Gleixner
Feb. 28, 2024, 10 p.m. UTC
The following commit has been merged into the sched/core branch of tip: Commit-ID: 7f1a7229718d788f26a711374da83adc2689837f Gitweb: https://git.kernel.org/tip/7f1a7229718d788f26a711374da83adc2689837f Author: David Vernet <void@manifault.com> AuthorDate: Mon, 05 Feb 2024 22:39:20 -06:00 Committer: Ingo Molnar <mingo@kernel.org> CommitterDate: Wed, 28 Feb 2024 15:19:24 +01:00 sched/fair: Do strict inequality check for busiest misfit task group In update_sd_pick_busiest(), when comparing two sched groups that are both of type group_misfit_task, we currently consider the new group as busier than the current busiest group even if the new group has the same misfit task load as the current busiest group. We can avoid some unnecessary writes if we instead only consider the newest group to be the busiest if it has a higher load than the current busiest. This matches the behavior of other group types where we compare load, such as two groups that are both overloaded. Let's update the group_misfit_task type comparison to also only update the busiest group in the event of strict inequality. Signed-off-by: David Vernet <void@manifault.com> Signed-off-by: Ingo Molnar <mingo@kernel.org> Reviewed-by: Vincent Guittot <vincent.guittot@linaro.org> Reviewed-by: Valentin Schneider <vschneid@redhat.com> Link: https://lore.kernel.org/r/20240206043921.850302-3-void@manifault.com --- kernel/sched/fair.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 41dda53..448520f 100644 --- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c @@ -10032,7 +10032,7 @@ static bool update_sd_pick_busiest(struct lb_env *env, * If we have more than one misfit sg go with the biggest * misfit. */ - if (sgs->group_misfit_task_load < busiest->group_misfit_task_load) + if (sgs->group_misfit_task_load <= busiest->group_misfit_task_load) return false; break;