Received: by 2002:ab2:6816:0:b0:1f9:5764:f03e with SMTP id t22csp257575lqo; Thu, 16 May 2024 05:44:10 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWc9X1hqks48h6TfcgjxEIH8HwUUUPfLdVwolSclRgnJDZRDPzp3tza1W/jj7wFOCRnXwJdusYMrubLe8LKI/cxrxt3VnBBDFK5crGq4A== X-Google-Smtp-Source: AGHT+IEjWC4P3GlqMTTa2iBse/pMi7+5y/FSyJ2MZ6mMeVDZkCAli9mB5lJ0G33Ws/Sq++B0C269 X-Received: by 2002:a05:6358:5694:b0:18d:b8bf:dff with SMTP id e5c5f4694b2df-193baed816cmr1867419555d.0.1715863449698; Thu, 16 May 2024 05:44:09 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715863449; cv=pass; d=google.com; s=arc-20160816; b=KaH2l3NZU+aCLZoZZJ4vqVstj6ewQx7ok8uav3STWO8/8zuKBW73/sedEsjG4lFvLm qDUsSPfsE6mxTdbnB9DaKuhjL2zrvnz7l0GVZzIHw0a7IPSdBa5CAZiouH/0cSbkPuBW 00dN9TOTZeAbdwPYikLNj3V4NSbmDdd1FwGmxofRf6nmuNaVHITIy9otZ1SpeQ9LsWR2 4O7majogXtYJ/0tjhhBuwyyJn1DiGvMjhmZddbjUly8k04V01OTrlrvS8HHHDuqHz0bY eZGbCQrlp+gIlZcZ4kWYVWCpkYrDnX5AVnt81SxSQcueZmFJgAMgGiP69FTPO2YxEKZ9 pVPQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :dkim-signature; bh=EymfovAPaOqIf8lLoq7gmRWeAEinSnJKTksVAj9AZKo=; fh=8DnxXQ8BpQC/X5AphjN4JmYLDXWZYSHVcQ3HPk41Zms=; b=MtyD/J/SjzdBuwXXyC6/vgc0YY3PU4GZqP4QQfvP9ibbAIgvT6ZGEWM/SvgL7T0G5L GeDfpcFwMTRHQauPMXDFQf5VeIUzPhHWpNuV8t/X05OM4po+HP+FxzGrimT1GK/PKEBD d5iRNKRD2BMQrAHGCaCvAdsBOFrrrjD2HaDSC/PXppj5TL/k29XOMXE9GIqS81Vx4ErK fIAFUcT7WsPvLB7DiymMFNfr25DBX/CHr534JBAYuHI+mwU/EW5fxuDjQww8oNP06tj9 BNPuD2HUrV4j6U2+lh1+CjdbmpQJLs2/rgbaZ6qC89YO5r8bFlnULjEpkx+Uo8BVewP4 bkfg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=JTMEdYqI; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-181047-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-181047-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id 41be03b00d2f7-63409d8d125si16035713a12.14.2024.05.16.05.44.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 16 May 2024 05:44:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-181047-linux.lists.archive=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=@gmail.com header.s=20230601 header.b=JTMEdYqI; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-181047-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-181047-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.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 E9880282322 for ; Thu, 16 May 2024 12:44:08 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 22999145FFE; Thu, 16 May 2024 12:44:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="JTMEdYqI" Received: from mail-yw1-f175.google.com (mail-yw1-f175.google.com [209.85.128.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E58BD335B5 for ; Thu, 16 May 2024 12:44:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.175 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715863443; cv=none; b=swJgpIAXXX4BFTSVNUhjgESmZhSikbV3HwYTN9w+IIPxSH3FojLzTy2qn6bA5UhIqX05HqrL9xt0/7m0FP7cH2dqxzUEzlPTgoJrzLQp2f9Nx8xoLNSmok0v8qWR4voLjwQLhrWaoCtNd+10CSFxdReOCxFHLN5x8+ukKPFFqa4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715863443; c=relaxed/simple; bh=ZE+ZF476CDghs+ffsIPZ9mw9R4UOZsjwNbsbIKcpz1w=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=Bk69xYSHz3uhy8c9pn93GVIcs9axQkpMQT57dZJvoMzx20mkSAqQ89eSS8VpBL20080Cnez9ikm52kK+S8xfJqYEe07Nq3ZMExPnuf1UPtqZv3ZFpn0ttnLY6T0U/ELRRBBG6ja8x0xy18LsL1gzqGtUx8WmGWdTQRv3/d0cOic= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=JTMEdYqI; arc=none smtp.client-ip=209.85.128.175 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-yw1-f175.google.com with SMTP id 00721157ae682-61df496df01so65786697b3.3 for ; Thu, 16 May 2024 05:44:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715863441; x=1716468241; darn=vger.kernel.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=EymfovAPaOqIf8lLoq7gmRWeAEinSnJKTksVAj9AZKo=; b=JTMEdYqIougv3WeyatidM6S2Yye56KbE+YFYNjB3QPhMIQGZ2ZK6N3ox82q3fJRUIG QpCgW8DTKsAwrkzKsWH92J2zpLISpSfWl6KGG8uo/xT19IPZLvCdFsMkmkpW6w0flC1X ZmK9X91GF2QwCPwtfhk4ikACw7QoZ8ObarcX49SRPeWzGzspifCGqiIojHY3bFq3Crdf 44bOsc20ZD4WCjFn4xVAdU2pDOZT3LrMphCjbJAMhmIuREWmnpWJRfrnGSjF0F82X5mo CUwbJ2XJrcDKbziJQcW0Kk4vFtdCIERF79LUV303Y51xCaFDLN4av+O4B2mZy1p9DZTa TEqw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715863441; x=1716468241; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=EymfovAPaOqIf8lLoq7gmRWeAEinSnJKTksVAj9AZKo=; b=Nl7xcrMcVHxR3hJwR2XT8qVs7O7drhKnSouhk8Sx6rj+/34jWyXs7/mEp0b6m87iC1 n3o7nKyD06186m8IDsapY/GA5CyFgyFtAk2J0b2D3kzD/+Iqlj130qSQs9cIgnkpsbJA O0uVQuuKyPZoDyvX8EnLm2CeWJokB6TjvFmCjDJLMyjcRI4A+XGSNk2XGle8ltBKZrG+ Y2XCbuLwyr1BWy3FVh3O9dWfi4N7yEw/Zp7Teesn1JR3hvFKwCvSsolIfUvOrWfmAY8T rT1iUP0SW4DoXkjOvvlgQGUx1IEgM3EUI1hoP9N+oQ9+3E7gHlMSnjXMIB1qFiXPI8dn onFg== X-Forwarded-Encrypted: i=1; AJvYcCVXYtUS0TgBM6UpzZ8uOfhTCbhB3UWc55kfcFvUKaEr7My3zMFZTU/YAPD+u80OUwZLvv1oWyIUk0UPCu8Ffz6s0fbP1qGrPtKKRdQ0 X-Gm-Message-State: AOJu0YzBYORfr48p3q3OBEz1DJB63SeMfgM7YNJYGYadFGpT/zdq0LJ7 8aQ6obbtwDrWuKse5yCsBSL3qoM8kmCW8p2Im6nqWymBJ1sb+Wtqx/MeYZfCwcux2eAYhNh+LJ9 Um/IoRdG0+V8RmlERpblvC3dpi1I= X-Received: by 2002:a81:6d05:0:b0:611:26e0:f24b with SMTP id 00721157ae682-622aff3c05emr181789987b3.9.1715863440861; Thu, 16 May 2024 05:44:00 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240508172621.30069-1-ppbuk5246@gmail.com> <20240509092931.35209-2-ppbuk5246@gmail.com> <20240516075628.GC22557@noisy.programming.kicks-ass.net> <20240516084911.GF22557@noisy.programming.kicks-ass.net> In-Reply-To: From: Yun Levi Date: Thu, 16 May 2024 13:43:49 +0100 Message-ID: Subject: Re: [PATCH v4] time/tick-sched: idle load balancing when nohz_full cpu becomes idle. To: Frederic Weisbecker Cc: Peter Zijlstra , Joel Fernandes , Vineeth Pillai , Vincent Guittot , Dietmar Eggemann , anna-maria@linutronix.de, mingo@kernel.org, tglx@linutronix.de, Markus.Elfring@web.de, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" > > > > As such, I don't think the HK_TYPE_SCHED check in > > > > nohz_balance_enter_idle() actually makes sense, the on_null_omain() > > > > check a little below that should already take care of things, no? > > > > > > IIUC, > > > currently, whether cpu belongs on domain or null is determined by > > > HK_DOMAIN_FLAGS > > > > No! you can create NULL domains without any of the HK nonsense. Both > > isolcpus and cpusets can create single CPU partitions. Yes. However what I said, nohz_full cpu isn't on null_domain unless it was configured by cpusets. even with option "nohz_full=" > > > However, when "nohz_full=" is used, it still on HK_DOMAIN, so it > > > belongs to sched_domain > > > so, it couldn't be filtered out by on_null_domain(). > > > > > > unless "isolcpus=domain" or "isolcpus={cpu_list}", it's on null domain. > > > with "isolcpus=tick", it participates sched_domain. > > > > Frederic ?!? You can use nohz_full without isolcpus? That makes no > > sense. If you do that you get to keep the pieces. > > I fear you can yes, even though most users combine it with isolcpus. I > know, that interface is terrible but it dates from times when we weren't > sure about all the potential usecases of nohz_full. There was a possibility > that HPC could just want to reduce ticks without all the hard and costly > isolation around. But all the usecases I have witnessed so far in ten years > involved wanting 0 noise after all... If I make you annoyed I'm sorry in advance but let me clarify please. 1. In case of none-HK-TICK-housekeeping cpu (a.k.a nohz_full cpu), It should be on the null_domain. right? 2. If (1) is true, when none-HK-TICK is set, should it set none-HK-DOMAIN to prevent on any sched_domain (cpusets filter out none-HK-DOMAIN cpu)? 3. If (1) is true, Is HK_SCHED still necessary? There seems to be no use case and the check for this can be replaced by on_null_domain(). Many thanks!