Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp5647230rwl; Tue, 11 Apr 2023 08:10:56 -0700 (PDT) X-Google-Smtp-Source: AKy350a7u0N5cS3wZToWfVzEFIyioWDNsMoijHPMu7B2bUVm+xcf911O5O/uRX8VaV6O3iTMsRZt X-Received: by 2002:aa7:d6d7:0:b0:4fc:709f:7ab0 with SMTP id x23-20020aa7d6d7000000b004fc709f7ab0mr10149657edr.0.1681225855631; Tue, 11 Apr 2023 08:10:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681225855; cv=none; d=google.com; s=arc-20160816; b=sPUozBtP0CB3xI+RXcBeDyk0Ee1vOESuDc7+eA163blRhQSm59AXaUjIow6PlAN+/5 edJLAhvPdjcZZLd2lTrvZddcO/Jtv593iZKGjp6LAz08V51H2mo3B5/HeVHdvlkiXWyJ r/guXMtOg2cSmSTwUmNL/M2qjzRKpS/q5oy5dwcluLnaJARbxYYrPSQLBJ+8E2JSIu6A VuUxLWV3RGTqevqzh8Ljse6Bh5uOYbt2CSkD/bhSh4i5mfnadpzvyM3ML1HgjDZ8NX3D wlyoH5arUUxsGf6E52V3VSW4OWZnlRgQeaNPkylRYcVeJPu1pmAUsiw5+ThkcXn3F8PW 0+zw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=m3tjzrn9vgH+epgdD39dTRsPzv4bId3KCAVUvytIiC0=; b=dlFJvgyhrKfd44ojtw+bVhHYzsqYniWtTFHxY4kBvMHFzwssdvfOcPeqEfhHt+652H deLCAs36pVKOK27Vqmj3/aonphEua69v+ER62FNsiQoNcYyNqcK5cumojlHHvp3b39JQ Csl9yQR/RExQ2BwgkGnWKkyV2eUiSAYk/EA6RtI/hJoPUCSrS/eSvg9UBUU5YZE2fGh4 jo7S9fN/DymORDfcMl2xE19/ZbCFFXwBCbE/QhNUrHaS0ifXWwc2EDUh7y22AuMs9z77 5i+eYFeGEDfc1w+fzkcb8k8ZhBMPS+tyz0JzLUS61g4jb12Yww3rDk/74psTEtsshsW+ K7Hw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=dADxETCk; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=suse.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w23-20020aa7d297000000b0050493797184si6419662edq.186.2023.04.11.08.10.00; Tue, 11 Apr 2023 08:10:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=dADxETCk; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=suse.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230354AbjDKPJW (ORCPT + 99 others); Tue, 11 Apr 2023 11:09:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36862 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230301AbjDKPJP (ORCPT ); Tue, 11 Apr 2023 11:09:15 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [IPv6:2001:67c:2178:6::1d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 93ED54C38; Tue, 11 Apr 2023 08:09:00 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 3D6B31FD76; Tue, 11 Apr 2023 15:08:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1681225739; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=m3tjzrn9vgH+epgdD39dTRsPzv4bId3KCAVUvytIiC0=; b=dADxETCkidHbUpn4IIj2ICcPpxGDuHfrP1gXYRRsuLhYsQn0UbF6NbrWWLvT/GogGsLdCz W7K+vzc+gH1JJ8ijeimOIV2lWQUJf521g9BxSR7iztTsrCUCzEWDS3QL9Sj6XvKHaPRI+x Y3khDEDd5T3Z18BbBWw7pXFl/map7EE= Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id C49F513638; Tue, 11 Apr 2023 15:08:58 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id 3rWbLgp4NWRVcgAAMHmgww (envelope-from ); Tue, 11 Apr 2023 15:08:58 +0000 Date: Tue, 11 Apr 2023 17:08:57 +0200 From: Michal =?utf-8?Q?Koutn=C3=BD?= To: Michal Hocko Cc: Gang Li , Waiman Long , cgroups@vger.kernel.org, linux-mm@kvack.org, rientjes@google.com, Zefan Li , linux-kernel@vger.kernel.org Subject: Re: [PATCH v4] mm: oom: introduce cpuset oom Message-ID: References: <20230411065816.9798-1-ligang.bdlg@bytedance.com> <3myr57cw3qepul7igpifypxx4xd2buo2y453xlqhdw4xgjokc4@vi3odjfo3ahc> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="5w72e4ixd2yvjwyd" Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.5 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --5w72e4ixd2yvjwyd Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Apr 11, 2023 at 03:12:34PM +0200, Michal Hocko wr= ote: > > Oh I see, you mean scanning all processes in all cpusets and scanning > > all processes globally are equivalent. >=20 > Why cannot you simple select a process from the cpuset the allocating > process belongs to? I thought the whole idea was to handle well > partitioned workloads. Ah, I was confused by the top_cpuset implementation. The iteration should then start in nearest_hardwall_ancestor(task_cs(current)). (in the 1st approximation). The nodes_intersect/nodes_subset/nodes_equal/whatnot heuristics is secondary. HTH, Michal --5w72e4ixd2yvjwyd Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQTrXXag4J0QvXXBmkMkDQmsBEOquQUCZDV4BQAKCRAkDQmsBEOq uWmbAP92Dw9zEkV1uoIFp/40jhHF8QWoTOvy5Wn27+Nam1QPeQD9Hd2xoA9doDrd EPYy/DQpuuQ7H3ogRM84kLZtmuSC2Aw= =MJ50 -----END PGP SIGNATURE----- --5w72e4ixd2yvjwyd--