Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp2241180pxp; Mon, 21 Mar 2022 14:44:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzF08jz9yAc2OCpkKWYoCyn3/BrKIoBISp+htvBn8JZrU5+Pj7pNcmd14yBEQNAZTwkm2J2 X-Received: by 2002:aa7:8432:0:b0:4f6:6dcd:4f19 with SMTP id q18-20020aa78432000000b004f66dcd4f19mr25945343pfn.53.1647899068033; Mon, 21 Mar 2022 14:44:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1647899068; cv=none; d=google.com; s=arc-20160816; b=DzNeobTmTgIP0U0xH3PTBEYvslTu8D1+a3PykpkuI5Gl4LYGJcUjL/Dp4F4eGq2MT9 MnJ+rwOJVPAqeXMrciIcRt5rZzKpn3/Uxg9HsAS0APNdPk2KZHQLsivKM9FluMer6gp3 qDQ9DelZt5f7zY2/HE9bSoCjf0mdxAo3sgk5gxzOpNZL799QAyLU8A1a88mg7uuUK1s+ 6Dro8Fihf3ggjUd6CBys9K5kpfqk1YbxJpblXhFJiDasLU2Jx/3eokX2qM4Up8XYVfGF F6PJvnHsXrT3ljzRhsLy4nsB9wCjsOOip19bdylNGWqj7CkALHU0+iA9QbgdW1oDZqNM FGlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=5ilDyZZOYXCfNmBJHbacQyWq4/CploWiU0eB3gs1qnY=; b=vzy60FvdzfTmCV0ZrRB+xL+uFZV+AhURjQjyrnNjKnnDncd4Y9WJTK+dkY3YgbGdHi qU8l82vGDA4yQFy0aE4lu4yrPreHoWGpdxgtvZA/eRhyAr1ACdxMnwtSwz8jADbqpkox r+3Ew28gz6N3KZBI0+ahf41w1eu/mreCody2Ej/qQcgnQpNSmjwJzGxPM5b5d+HvftbZ zlOV1fuQHf5Hd1gbajPGMUmwE6FF+7reXSbZK+wL8u0XxbNHcr2QQq2alLTpZYrUoHn+ rPcfCpDoefjdsdYbc+cIYEveFBYdLLo7ld3exyaW/c1mpY3OVQ3qgP4WoDrr1agwFltG dWiw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=0cxr2THZ; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id y19-20020a056a00181300b004fa3a8dff4dsi2180668pfa.4.2022.03.21.14.44.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 21 Mar 2022 14:44:28 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=0cxr2THZ; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 90DC22AD0B3; Mon, 21 Mar 2022 14:16:58 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1353447AbiCUUkA (ORCPT + 99 others); Mon, 21 Mar 2022 16:40:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39328 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1353445AbiCUUj4 (ORCPT ); Mon, 21 Mar 2022 16:39:56 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2743A114D for ; Mon, 21 Mar 2022 13:38:29 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id AEA1FB819DF for ; Mon, 21 Mar 2022 20:38:27 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 31668C340E8; Mon, 21 Mar 2022 20:38:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1647895106; bh=OG92xJeUwmKMGHqIl3VXi668zYVeg8l5O+7ghW3iQkY=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=0cxr2THZKnIss7cBYqAUzeIZ7n24+n520EMDWb0IJfAESx3xD+YqkutRB9mtW7myn DN/wvEBRvR43A38ZEaJsNmxSxHxONialgBFaKpU2wxswPlRZ/OGJveVpSOXYSYYaeq a2FBcCKgkPPcHWVmLt1kVzAKMGgGELnqEW3Bl0MU= Date: Mon, 21 Mar 2022 13:38:25 -0700 From: Andrew Morton To: Sean Anderson Cc: Yinan Zhang , linux-kernel@vger.kernel.org Subject: Re: [PATCH] tools/vm/page_owner_sort.c: add switch between culling by stacktrace and txt Message-Id: <20220321133825.6f003c62381edbab361a8d96@linux-foundation.org> In-Reply-To: References: <20211129145658.2491-1-zhangyinan2019@email.szu.edu.cn> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,NICE_REPLY_A,RDNS_NONE,SPF_HELO_NONE, T_SCC_BODY_TEXT_LINE autolearn=no 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 These comments were not responded to: On Mon, 29 Nov 2021 21:23:41 -0500 Sean Anderson wrote: > > This is working as designed. IMO there's no point in separating > allocations like this which differ only in PID and timestamp, since you > will get no grouping at all. > > > The info of second block missed. So, add -c to turn on culling > > by stacktrace. By default, it will cull by txt. > > Please keep the default to actually do something in the cull step. > > ... > > > @@ -162,6 +171,9 @@ int main(int argc, char **argv) > > case 't': > > cmp = compare_num; > > break; > > + case 'c': > > + cull_st = 1; > > + break; > > Can we set a "cull_cmp" variable like cmp? > > Looking forward, I think something like > > page_owner_sort --cull=stacktrace --sort=times foo bar > > would be nice. > Which is unfortunate. I'll send the patch in to Linus anyway, as many other patches syntactically depend on it. Please work with Sean to address these issues and lets get this resolved over the next few weeks. Also, please cc linux-mm@kvack.org on changes to page_owner.