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 X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3B823C55ABD for ; Thu, 12 Nov 2020 19:14:41 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id A2C902223F for ; Thu, 12 Nov 2020 19:14:40 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="Z26vT4aM" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A2C902223F Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id EA85B6B0036; Thu, 12 Nov 2020 14:14:39 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id E59916B005C; Thu, 12 Nov 2020 14:14:39 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id D20A26B0068; Thu, 12 Nov 2020 14:14:39 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0054.hostedemail.com [216.40.44.54]) by kanga.kvack.org (Postfix) with ESMTP id 9F6356B0036 for ; Thu, 12 Nov 2020 14:14:39 -0500 (EST) Received: from smtpin19.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 3E39A1EF2 for ; Thu, 12 Nov 2020 19:14:39 +0000 (UTC) X-FDA: 77476717878.19.women26_050ed5a27308 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin19.hostedemail.com (Postfix) with ESMTP id 154E11AD1B2 for ; Thu, 12 Nov 2020 19:14:39 +0000 (UTC) X-HE-Tag: women26_050ed5a27308 X-Filterd-Recvd-Size: 2643 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by imf03.hostedemail.com (Postfix) with ESMTP for ; Thu, 12 Nov 2020 19:14:38 +0000 (UTC) Received: from localhost.localdomain (c-73-231-172-41.hsd1.ca.comcast.net [73.231.172.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id C13DB20B80; Thu, 12 Nov 2020 19:14:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605208477; bh=CQVrsFhxionALStdHqSmv142xPjtDpVoDmH7rt3JLrs=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=Z26vT4aMSGqAp0sVbnHuMR0uVxLCBTcSlxFb7/2U0jfyII9e4vT1jV/5prGT1ap7w 6VIn+2HY2sOE2Y4VNyK4dEqzXYavtN9rgMADFFBGHH05hJnMJHwXNDUPHWgZZxaT8p uT54M/AtWDXghvMBtV+mxfqdHeOGt0gh7vq1hc20= Date: Thu, 12 Nov 2020 11:14:36 -0800 From: Andrew Morton To: Georgi Djakov Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, sudaraja@codeaurora.org, pratikp@codeaurora.org, lmark@codeaurora.org Subject: Re: [PATCH] mm/page_owner: Record timestamp and pid Message-Id: <20201112111436.c5deeadd3578877fc0b844a1@linux-foundation.org> In-Reply-To: <20201112184106.733-1-georgi.djakov@linaro.org> References: <20201112184106.733-1-georgi.djakov@linaro.org> X-Mailer: Sylpheed 3.5.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit 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 Thu, 12 Nov 2020 20:41:06 +0200 Georgi Djakov wrote: > From: Liam Mark > > Collect the time for each allocation recorded in page owner so that > allocation "surges" can be measured. > > Record the pid for each allocation recorded in page owner so that > the source of allocation "surges" can be better identified. Please provide a description of why this is considered useful. What has it been used for, what problems has it been used to solve? Are there userspace tools which aid in the processing of this new information? Can/should Documentation/vm/page_owner.rst be updated? > --- a/mm/page_owner.c > +++ b/mm/page_owner.c > @@ -10,6 +10,7 @@ > #include > #include > #include > +#include > > #include "internal.h" > > @@ -25,6 +26,8 @@ struct page_owner { > gfp_t gfp_mask; > depot_stack_handle_t handle; > depot_stack_handle_t free_handle; > + u64 ts_nsec; > + int pid; pid_t would be nicer?