Received: by 2002:ab2:6857:0:b0:1ef:ffd0:ce49 with SMTP id l23csp2741637lqp; Mon, 25 Mar 2024 08:03:49 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVACTbyn/g1DnUhYr+/EicWmrKCmPQ+pLeddbq/kdz8P8loSNV2j6tpimpR1Pgc8q1c3A110Gx0BunaiewLXTlGnXiyO9d+qrjhofYFmQ== X-Google-Smtp-Source: AGHT+IHIqAM/8/SqkQDNyIKQCV8N7+o0tzYgZR8TuOmTn0req+BXb5KrUmzPN5oF6k0FhQvVkbwP X-Received: by 2002:a05:6358:4e10:b0:17f:88fb:5bd5 with SMTP id ld16-20020a0563584e1000b0017f88fb5bd5mr2432154rwc.20.1711379029134; Mon, 25 Mar 2024 08:03:49 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711379029; cv=pass; d=google.com; s=arc-20160816; b=t/bQIXNRWBkLypd+9UMN0OfadsNuU90fSamx/21y5BeTlgWXvXF8/taSh76p7YqOYc qP957H9CN2E6P1/o01vfVZIUi15C6i08OuXwbQ9lhAXPiX9oEcW3PHvt9PTTo0QCmOoC C6m8lBshNQYGelRSEes5hIXbpPph9/GYdI+sb1v8yCGN9roQYFrcFlfNe1dPK5pOqyTF W+XoTEQrMgBDjZC6RwXBYqO7CfEI5A17wT9JHdOHBAlpe/MYags5UJXhtwhjg90SlT51 7fkHJyMCfbssWL0c3Sh9w9xJ9TN7CjAb8Cai2Xv+q9baEsGcovhhj+wMCveod67XxQD2 zkgw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:list-unsubscribe:list-subscribe:list-id:precedence :content-transfer-encoding:in-reply-to:content-language:from :references:cc:to:subject:user-agent:date:message-id:dkim-signature; bh=jXWX8mwJBS3pmxEX7wnapQBypJUxG/fCxgLjHBdv+Tw=; fh=IUTKkUpM3hzjb4qw+9jBjI9wAJpsNMyLrKKOo1Tpl+E=; b=CIGgIksZPQjrmbOwOAhKy1zoXc4/c2n+wose5mxEwyLzFGC6GSPDEqqRKbtb/qLZfb GSmHXoKJswNAyd71AtBldgC6sJdYrBTaOA2VZ+i1h5CQUmxuED2kL7qDL6UIgQs0fKEQ fgjoNiortTUC+cKYedYCGzgBnJJTfcDzw0YEUMHdSarT0jFm9GgvE6fd2c3o4GzEAthw EoV2LpaZzJkgmYdY55Aazq6nL92zaYjwr0FJxkeBBCUY67cr08jCoW4P7FOg42vVnpCd L2zVr1MQ2Qu+ukYqOkIFbgZ7cnVvwlyeNAH5Spst/1rbChForHKwfDluD1CJY3o8xYeH L9Vw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=cWp42Zi2; arc=pass (i=1 spf=pass spfdomain=linux.ibm.com dkim=pass dkdomain=ibm.com dmarc=pass fromdomain=linux.ibm.com); spf=pass (google.com: domain of linux-kernel+bounces-116948-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-116948-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id q16-20020a635050000000b005e438e96ae6si7533785pgl.601.2024.03.25.08.03.48 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Mar 2024 08:03:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-116948-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=cWp42Zi2; arc=pass (i=1 spf=pass spfdomain=linux.ibm.com dkim=pass dkdomain=ibm.com dmarc=pass fromdomain=linux.ibm.com); spf=pass (google.com: domain of linux-kernel+bounces-116948-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-116948-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=NONE dis=NONE) header.from=ibm.com 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 F29612E644E for ; Mon, 25 Mar 2024 14:56:02 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 78DB11C5AD3; Mon, 25 Mar 2024 11:58:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b="cWp42Zi2" Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) (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 60B5616ABF1 for ; Mon, 25 Mar 2024 11:33:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=148.163.156.1 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711366414; cv=none; b=bHoJOBrEtsMXeAUO1QPTXyRFZsApvsJRlWXBbgm+Uu4gUKgoeGMFdhSrNEGKMwezfbyySGvA48x/36GJtxoCpeMRKMWiSlMcTTATFvTOcy67NUJDXkG6xFZwOuKA1YUpP0XjMSHjSo1lSsP2ljW83tagqQZ4XcIrFlPiAYfbInU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711366414; c=relaxed/simple; bh=ElIwG6psa/J4635YmK5pkDzO7EjX+/RBo0kQUz9jl0M=; h=Message-ID:Date:Subject:To:Cc:References:From:In-Reply-To: Content-Type:MIME-Version; b=sKreW6YuMxONxGMPwLhedvOgJj5Au+sM745Z3qkoNDNlA3lc0JrhQDOm0OIiHRu78RB84K1y8rl6pI6JuaUYXnv3/040bNv5Yg0LNpxzDKGs+2zwtkBFZ5r/8FCuKcfFLr+K87ze0aGsGG6dMWOeMrVLm8IM/X5OhbfByWqiFms= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.ibm.com; spf=pass smtp.mailfrom=linux.ibm.com; dkim=pass (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b=cWp42Zi2; arc=none smtp.client-ip=148.163.156.1 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.ibm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.ibm.com Received: from pps.filterd (m0356517.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 42PARjem021184; Mon, 25 Mar 2024 11:33:18 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=message-id : date : subject : to : cc : references : from : in-reply-to : content-type : content-transfer-encoding : mime-version; s=pp1; bh=jXWX8mwJBS3pmxEX7wnapQBypJUxG/fCxgLjHBdv+Tw=; b=cWp42Zi2mFDJ4WsHQVRiB3LOVdC1LOcTrgF0DP1w/tBXQ2xSjaXj+v3AhgpMrXVmBuEy ltMCelaDY24P4UW2NW8TfvZ3yjMM8ZRw71uM1Y3TXu7ZNqJtK3mtrtFc/1oydC0nVrbG A+PbgnAerxyfCpI3bG+EEWWyHixjeC7B7os4KSge2VCt5KchrQzvY8HSEebKiTfygd9y Io8YlNEv5Ed/pKBTgVdFXzS/LbE7ExPT2IUGg7OU8vjh+AaS5HtWaWBFcGNhozk/Itjz xuXnsYL9ODI50hgDNV8uw7QALCSvJa05YwQAhVPG96dm7H9xjic/iBOCNY2f10ZWlzg8 Cw== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3x37hd83pt-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 25 Mar 2024 11:33:17 +0000 Received: from m0356517.ppops.net (m0356517.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 42PBXHip022393; Mon, 25 Mar 2024 11:33:17 GMT Received: from ppma22.wdc07v.mail.ibm.com (5c.69.3da9.ip4.static.sl-reverse.com [169.61.105.92]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3x37hd83pm-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 25 Mar 2024 11:33:17 +0000 Received: from pps.filterd (ppma22.wdc07v.mail.ibm.com [127.0.0.1]) by ppma22.wdc07v.mail.ibm.com (8.17.1.19/8.17.1.19) with ESMTP id 42PBAaZg012991; Mon, 25 Mar 2024 11:33:16 GMT Received: from smtprelay07.dal12v.mail.ibm.com ([172.16.1.9]) by ppma22.wdc07v.mail.ibm.com (PPS) with ESMTPS id 3x29t08yfp-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 25 Mar 2024 11:33:16 +0000 Received: from smtpav01.dal12v.mail.ibm.com (smtpav01.dal12v.mail.ibm.com [10.241.53.100]) by smtprelay07.dal12v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 42PBXDJc44302652 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 25 Mar 2024 11:33:15 GMT Received: from smtpav01.dal12v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 5805D5806B; Mon, 25 Mar 2024 11:33:13 +0000 (GMT) Received: from smtpav01.dal12v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 5916E58057; Mon, 25 Mar 2024 11:33:11 +0000 (GMT) Received: from [9.195.43.175] (unknown [9.195.43.175]) by smtpav01.dal12v.mail.ibm.com (Postfix) with ESMTP; Mon, 25 Mar 2024 11:33:11 +0000 (GMT) Message-ID: <3c92c18b-6a19-4477-9972-1219c29b3d71@linux.ibm.com> Date: Mon, 25 Mar 2024 17:03:10 +0530 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v3 0/2] sched: Minor changes for rd->overload access To: Ingo Molnar Cc: peterz@infradead.org, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, qyousef@layalina.io, linux-kernel@vger.kernel.org, vschneid@redhat.com References: <20240325054505.201995-1-sshegde@linux.ibm.com> From: Shrikanth Hegde Content-Language: en-US In-Reply-To: Content-Type: text/plain; charset=UTF-8 X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: vGoJulDxx4BD7hWdjfuqKVZ0zkpa4uwL X-Proofpoint-GUID: RszKkONAwqbIIyRBcORzEMPjq9FoTwiA Content-Transfer-Encoding: 7bit X-Proofpoint-UnRewURL: 0 URL was un-rewritten Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.1011,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2024-03-25_08,2024-03-21_02,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 adultscore=0 lowpriorityscore=0 bulkscore=0 spamscore=0 priorityscore=1501 phishscore=0 malwarescore=0 suspectscore=0 clxscore=1015 mlxscore=0 mlxlogscore=697 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2403210000 definitions=main-2403250064 On 3/25/24 4:06 PM, Ingo Molnar wrote: > > * Shrikanth Hegde wrote: > >> v2 -> v3: >> - Wrapped check for value change inside ser_rd_overload_status >> as suggested by Qais. >> - Added reviewed-by tags. >> >> v1 -> v2: >> - dropped Fixes tag. >> - Added one of the perf probes in the changelog for reference. >> - Added reviewed-by tags. >> >> tl;dr >> When running workloads in large systems, it was observed that access to >> rd->overload was taking time. It would be better to check the value >> before updating since value changes less often. Patch 1/2 does that. >> With patch updates happen only if necessary. CPU Bus traffic reduced a >> bit. No significant gains in workload performance. > > Could you please post this against the latest scheduler tree, ie. tip:sched/core? > > Thanks, > > Ingo Hi Ingo. I had mentioned the same in cover letter. Sorry if I didn't mention it in the correct place. *These patches depend on below to be applied first* https://lore.kernel.org/all/20240307085725.444486-1-sshegde@linux.ibm.com/ After that the above patch would apply. I kept the dependency since these are in similar code area. Can we please consider the above patch as well? Is there any other change that needs to be done? On tip 1043c003415b (HEAD -> master) sched/fair: Use helper functions to access rd->overload 3049bc16643d sched/fair: Check rd->overload value before update 436d634f2cad sched/fair: Combine EAS check with overutilized access 379aa2cd62e0 sched/fair: Use helper function to access rd->overutilized 19bfeb2d565e sched/fair: Add EAS checks before updating overutilized 71706005072c (origin/master, origin/HEAD) Merge branch into tip/master: 'x86/shstk' fa63c2c111ea (HEAD -> sched/core) sched/fair: Use helper functions to access rd->overload 9bef486d044b sched/fair: Check rd->overload value before update 21f90cae75c8 sched/fair: Combine EAS check with overutilized access e835f1fa3654 sched/fair: Use helper function to access rd->overutilized ddf390f9449d sched/fair: Add EAS checks before updating overutilized 58eeb2d79b54 (origin/sched/core) sched/fair: Don't double balance_interval for migrate_misfit