From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id CFB31C04AA5 for ; Thu, 25 Aug 2022 09:52:12 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 6B598940007; Thu, 25 Aug 2022 05:52:12 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 665976B0075; Thu, 25 Aug 2022 05:52:12 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 52CCE940007; Thu, 25 Aug 2022 05:52:12 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id 409E36B0074 for ; Thu, 25 Aug 2022 05:52:12 -0400 (EDT) Received: from smtpin10.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id 0CAFF1A0A11 for ; Thu, 25 Aug 2022 09:52:12 +0000 (UTC) X-FDA: 79837649304.10.06665E9 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by imf25.hostedemail.com (Postfix) with ESMTP id 7AE9BA0002 for ; Thu, 25 Aug 2022 09:52:11 +0000 (UTC) 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 07CB31FB0B; Thu, 25 Aug 2022 09:52:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1661421130; h=from:from:reply-to: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=e6vFISPJN3U6nScOiLDA2IhWeXOoQm4ccfrelohfpXs=; b=pbDJSVXlyKdEGh36m+cnk5iqpJEsmDB3R+cx4aNbCfjV+058Z0x64m3vYJ739nYXroPGcg GVLhqwUqlHmxESlVNtyS2EndoUQnqC25ljNRgJQ6pCPkh1Uk/FFnMjm68mBRAnm0NG9L/+ a95eLekDWoioMa6e33sFLmkJDxYbtSI= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1661421130; h=from:from:reply-to: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=e6vFISPJN3U6nScOiLDA2IhWeXOoQm4ccfrelohfpXs=; b=I5DrCQqkgcn62snMSlJVS5ah4CueLwPA1qyy+F9mr7yiHTGCBHht4b6fXxzwKxMTD4CnhP vJJ4M4i9yjkV3JCw== 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 D8DB813A8E; Thu, 25 Aug 2022 09:52:09 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id VfAcNElGB2MKUQAAMHmgww (envelope-from ); Thu, 25 Aug 2022 09:52:09 +0000 Message-ID: Date: Thu, 25 Aug 2022 11:52:09 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.1.2 Subject: Re: [RFC PATCH] mm: reduce noise in show_mem for lowmem allocations Content-Language: en-US To: Michal Hocko , linux-mm@kvack.org Cc: Christoph Hellwig , Andrew Morton , Mel Gorman , Johannes Weiner , LKML References: From: Vlastimil Babka In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit ARC-Authentication-Results: i=1; imf25.hostedemail.com; dkim=pass header.d=suse.cz header.s=susede2_rsa header.b=pbDJSVXl; dkim=pass header.d=suse.cz header.s=susede2_ed25519 header.b=I5DrCQqk; spf=pass (imf25.hostedemail.com: domain of vbabka@suse.cz designates 195.135.220.29 as permitted sender) smtp.mailfrom=vbabka@suse.cz; dmarc=none ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1661421131; a=rsa-sha256; cv=none; b=GP2N170ODyIuw0+Ez70ggjlWkpSlDNZ9iGFmSuF63Z62lYwdWF0FkalpF65KE9OiCMGSEv VzJL/m3aST1SH05qiobkFLP9k9yiSkDu57bm+pT46/YsS2/Uq6Q1vywv8/Kcoeco/h0ndR FkVd5/weclqtsea9B03sBht27BxK1DU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1661421131; h=from:from:sender: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:dkim-signature; bh=e6vFISPJN3U6nScOiLDA2IhWeXOoQm4ccfrelohfpXs=; b=7rcrVKZ8GxxFtpjUH3ItR4q0+AGaK0rWAeoSRqpisLo3nTQXCIGsabb6pu9yPHbMXvXdtq hb2SLIWl7csoXEzbEZ4T/HHi6ixFiv8EKq7513q7io0qV4kceBY1PGPn9O0sbNYQYECYbS vuIBRrg7KHDA+8UkyFLyWyxAZpUk8AA= Authentication-Results: imf25.hostedemail.com; dkim=pass header.d=suse.cz header.s=susede2_rsa header.b=pbDJSVXl; dkim=pass header.d=suse.cz header.s=susede2_ed25519 header.b=I5DrCQqk; spf=pass (imf25.hostedemail.com: domain of vbabka@suse.cz designates 195.135.220.29 as permitted sender) smtp.mailfrom=vbabka@suse.cz; dmarc=none X-Rspam-User: X-Stat-Signature: 39sqtn7hgotah8xsue416k5qfq75hj17 X-Rspamd-Queue-Id: 7AE9BA0002 X-Rspamd-Server: rspam04 X-HE-Tag: 1661421131-41623 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On 8/23/22 11:22, Michal Hocko wrote: > All but node0 are really completely irrelevant for this allocation > because they do not have ZONE_DMA yet it swamps the log and makes it > harder to visually inspect. > > Address this by providing gfp_maks parameter to show_mem and filter the > output to only those zones/nodes which are relevant for the allocation. > That means nodes which have at least one managed zone which is usable > for the allocation (zone_idx(zone) <= gfp_zone(gfp_mask)). > The resulting output for the same failure would become: Looks good to me. > [...] > [ 14.017605][ T1] Mem-Info: Maybe print the gfp_mask (or just max zone) here again, to make it more obvious in case somebody sents a report without the top header? > [ 14.017956][ T1] active_anon:0 inactive_anon:0 isolated_anon:0 > [ 14.017956][ T1] active_file:0 inactive_file:0 isolated_file:0 > [ 14.017956][ T1] unevictable:0 dirty:0 writeback:0 > [ 14.017956][ T1] slab_reclaimable:876 slab_unreclaimable:30300 > [ 14.017956][ T1] mapped:0 shmem:0 pagetables:12 bounce:0 > [ 14.017956][ T1] free:3170151735 free_pcp:6868 free_cma:0 > [ 14.017962][ T1] Node 0 active_anon:0kB inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:0kB isolated(anon):0kB isolated(file):0kB mapped:0kB dirty:0kB writeback:0kB shmem:0kB shmem_thp: 0kB shmem_pmdmapped: 0kB anon_thp: 0kB writeback_tmp:0kB kernel_stack:7200kB pagetables:4kB all_unreclaimable? no > [ 14.018026][ T1] Node 0 DMA free:160kB boost:0kB min:0kB low:0kB high:0kB reserved_highatomic:0KB active_anon:0kB inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:0kB writepending:0kB present:15996kB managed:15360kB mlocked:0kB bounce:0kB free_pcp:0kB local_pcp:0kB free_cma:0kB > [ 14.018035][ T1] lowmem_reserve[]: 0 0 0 0 0 > [ 14.018339][ T1] Node 0 DMA: 0*4kB 0*8kB 0*16kB 1*32kB (U) 0*64kB 1*128kB (U) 0*256kB 0*512kB 0*1024kB 0*2048kB 0*4096kB = 160kB > [ 14.018480][ T1] 0 total pagecache pages > [ 14.018483][ T1] 0 pages in swap cache > [ 14.018484][ T1] Swap cache stats: add 0, delete 0, find 0/0 > [ 14.018486][ T1] Free swap = 0kB > [ 14.018487][ T1] Total swap = 0kB > [ 14.018488][ T1] 3221164600 pages RAM > [ 14.018489][ T1] 0 pages HighMem/MovableOnly > [ 14.018490][ T1] 50531051 pages reserved > [ 14.018491][ T1] 0 pages cma reserved > [ 14.018492][ T1] 0 pages hwpoisoned > > Signed-off-by: Michal Hocko