Received: by 2002:a05:7412:d1aa:b0:fc:a2b0:25d7 with SMTP id ba42csp440932rdb; Mon, 29 Jan 2024 07:04:39 -0800 (PST) X-Google-Smtp-Source: AGHT+IFpMHmqJXms1N2/SecdvrAgZmhKOqLxrjHS+WIwGIt05HkExG1rmFy62+e6UPF6E6Roludz X-Received: by 2002:a17:907:76e1:b0:a35:f93b:2dd2 with SMTP id kg1-20020a17090776e100b00a35f93b2dd2mr517596ejc.7.1706540679674; Mon, 29 Jan 2024 07:04:39 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706540679; cv=pass; d=google.com; s=arc-20160816; b=mwfM2YiW8DzB1FtTw03VYWmhaLlZ1KZRFgdvqrtqbEG3vsBoZNPZ9GdC7PovzyhwKD NIznPEzD74S35aeIcqt4k197Y/cpL2Lw7WsaZnMMTFfpUS7ZPf6QmpoBDnhN5B2xKt2i cCkp1yu1niZnA++ws9jIfM5QQwcmUVBgfIo23IXUBRhYKN4Z2WdeT5qWDgJp62b8p2zT iO5vI8PcAUfQW+fMbiAdGmC/U++4YOikS9AjLKR4Wwn/ZR1bcLDLS6ITAC14GS9hP+KN G31IyDTcpvhv6uKO0bRX3puDxK14gAC+xfj4jybvgiZ+0vdNyBEFEL+msftDyD2G1Y3x rWEQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature:dkim-signature; bh=qLDYdWmw6CK2qQtrHRQgWWQYsKvJNWhiGQv/PrF1tIo=; fh=px2436vcxvTDYcCBVP9YULZ/hheD2LKJVtCEdHESsMM=; b=dkUOnOXJFTQRrA/nNliVUEcnx6Ppnn2VbnIkZvjRTpmvpy4OBsfHNA3V83fsCAEj9G CEHngJt2lkRaVp9R5KcuqaFyOytjjyCw9SabbRuPfT0rEOIBtS46yWUq18YXX4QZjb7a gT4gRragOfJsjU5VC7Y0gDOA3YSIaA2qaehzzxiVbpKIV9nabj5oDBzl5y5tzNn4XMh5 G2LHtYZ4MPsRmsD5PVeNA8MBubmZo2b8UbcRFG7gutRr1CpT02dIzCm7VsYKiSAhVBAR t1GoMNK4X3MObR2XYBdCqBNOh9UeDz0JWimlDugDJsCWJhNhGdU69Qs19ksOdEHNUnlL fzyA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=saGxSX6N; dkim=pass header.i=@suse.com header.s=susede1 header.b=rggoIBsx; arc=pass (i=1 spf=pass spfdomain=suse.com dkim=pass dkdomain=suse.com dkim=pass dkdomain=suse.com dmarc=pass fromdomain=suse.com); spf=pass (google.com: domain of linux-kernel+bounces-42955-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-42955-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=suse.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id g15-20020a17090613cf00b00a35b5f5d866si1034532ejc.47.2024.01.29.07.04.39 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 29 Jan 2024 07:04:39 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-42955-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=saGxSX6N; dkim=pass header.i=@suse.com header.s=susede1 header.b=rggoIBsx; arc=pass (i=1 spf=pass spfdomain=suse.com dkim=pass dkdomain=suse.com dkim=pass dkdomain=suse.com dmarc=pass fromdomain=suse.com); spf=pass (google.com: domain of linux-kernel+bounces-42955-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-42955-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=suse.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 am.mirrors.kernel.org (Postfix) with ESMTPS id 6E5821F28852 for ; Mon, 29 Jan 2024 15:04:39 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6A9911534F6; Mon, 29 Jan 2024 15:04:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=suse.com header.i=@suse.com header.b="saGxSX6N"; dkim=pass (1024-bit key) header.d=suse.com header.i=@suse.com header.b="rggoIBsx" Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) (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 AB277152E03 for ; Mon, 29 Jan 2024 15:04:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=195.135.223.130 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706540672; cv=none; b=ouqCET+sC7L/UGS5423TbAxj2w5KAyruk04KeVH0kLE0XUTz9Uj/rW0BM0FariNSK4+0LxPe1QP4sMng/ZBUTzN4Sb8TI30nS11MQt64cU3bOwFA+Nijc0V9Ym8Q1DAnRu6GBEc3kv4G0pkKJgyXJQGlg3HUxYVF7GNLZQppeak= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706540672; c=relaxed/simple; bh=W71jzVeX/ucO0N44eoO+UKhuasj/ay4HyG1qWOve9E0=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=HyPcjJrKt8Dk0ARSOiisZvETK76oR8AJF+V7mXbyuQ89YqzzKbTb/oQn+J/WIRI/uTyK3dw9sXAIPG9JhdpLFMsKeVixqVzP6DSLE8iaVy3Nfq3jFmaX+Bm4Gr5Sv4PoHvWy8bQMkdg/6Lhx51YSA9gnO8LOLxXwYFnbiHh9pmU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com; spf=pass smtp.mailfrom=suse.com; dkim=pass (1024-bit key) header.d=suse.com header.i=@suse.com header.b=saGxSX6N; dkim=pass (1024-bit key) header.d=suse.com header.i=@suse.com header.b=rggoIBsx; arc=none smtp.client-ip=195.135.223.130 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=suse.com Received: from imap1.dmz-prg2.suse.org (imap1.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id DF0182229F; Mon, 29 Jan 2024 15:04:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1706540669; 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=qLDYdWmw6CK2qQtrHRQgWWQYsKvJNWhiGQv/PrF1tIo=; b=saGxSX6N5mcW8/z9thvLMK5caQHOHCBZJOPUGc0sZVhwRuZhazmNFySksz/OUxiFGC+aii gFBHXnKLFwF+cae2M10qPoLPX62/20ECeUB3vaIiMFqkHNdV1VMJFP6yOGHhNchvCTFz7t TYb8b1Spj0lqrux2CAqcSZxPvn5OK94= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1706540668; 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=qLDYdWmw6CK2qQtrHRQgWWQYsKvJNWhiGQv/PrF1tIo=; b=rggoIBsxma3yEW0oIshlsDtMevx74QEdciEc1yYE5AR2UwDobVchyv9b5u3O4s3D0rLLtV NXVXH28qVvWl1y2zAZJq5v4EeWU05vKrPBfELxDMwg0RKz1ediHLRmvctsqwICrdJWtPNZ CVo1J7VZboxv8X0TS+KUWSPWVFGinVo= Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id C0AC312FF7; Mon, 29 Jan 2024 15:04:28 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap1.dmz-prg2.suse.org with ESMTPSA id NHzoK3y+t2UQPwAAD6G6ig (envelope-from ); Mon, 29 Jan 2024 15:04:28 +0000 Date: Mon, 29 Jan 2024 16:04:28 +0100 From: Michal Hocko To: Zach O'Keefe Cc: Charan Teja Kalla , akpm@linux-foundation.org, mgorman@techsingularity.net, david@redhat.com, vbabka@suse.cz, hannes@cmpxchg.org, quic_pkondeti@quicinc.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Axel Rasmussen , Yosry Ahmed , David Rientjes Subject: Re: [PATCH V3 3/3] mm: page_alloc: drain pcp lists before oom kill Message-ID: References: <5c7f25f9-f86b-8e15-8603-e212b9911cac@quicinc.com> <342a8854-eef5-f68a-15e5-275de70e3f01@quicinc.com> <5adb12eb-8403-5860-28eb-5f6ab12f3c04@quicinc.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Level: Authentication-Results: smtp-out1.suse.de; dkim=pass header.d=suse.com header.s=susede1 header.b=rggoIBsx X-Rspamd-Server: rspamd2.dmz-prg2.suse.org X-Spamd-Result: default: False [-2.54 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_DKIM_ALLOW(-0.20)[suse.com:s=susede1]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:97:from]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[text/plain]; NEURAL_HAM_SHORT(-0.20)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; DKIM_TRACE(0.00)[suse.com:+]; MX_GOOD(-0.01)[]; RCPT_COUNT_TWELVE(0.00)[13]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:dkim]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; MID_RHS_NOT_FQDN(0.50)[]; RCVD_TLS_ALL(0.00)[]; BAYES_HAM(-1.53)[91.96%] X-Spam-Score: -2.54 X-Rspamd-Queue-Id: DF0182229F X-Spam-Flag: NO On Fri 26-01-24 14:51:26, Zach O'Keefe wrote: [...] > Node 0 DMA32 free:66592kB min:2580kB low:5220kB high:7860kB [...] > free_pcp:8040kB local_pcp:244kB free_cma:0kB > lowmem_reserve[]: 0 0 16029 16029 > Node 0 Normal free:513048kB min:513192kB low:1038700kB high:1564208kB [...] > mlocked:12344kB bounce:0kB free_pcp:790040kB local_pcp:7060kB [...] > mlocked:1588kB bounce:0kB free_pcp:253500kB local_pcp:12kB [...] > I'm not familiar with these changes, but a quick check of recent > activity points to v6.7 commit fa8c4f9a665b ("mm: fix draining remote > pageset") ; is this what you are referring to? No, but looking at above discrepancy between free_pcp and local_pcp would point that direction for sure. So this is worth checking. vmstat is a periodic activity and it cannot really deal with bursts of memory allocations but it is quite possible that the patch above will prevent the build up before it grows that large. I originally referred to different work though https://lore.kernel.org/all/20231016053002.756205-10-ying.huang@intel.com/T/#m9fdfabaee37db1320bbc678a69d1cdd8391640e0 merged as ca71fe1ad922 ("mm, pcp: avoid to drain PCP when process exit") and the associated patches. -- Michal Hocko SUSE Labs