Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp753195rwb; Thu, 10 Nov 2022 07:03:41 -0800 (PST) X-Google-Smtp-Source: AMsMyM4//se/WilAnYSHo/56qI52jxfwNmwHOAwvlSllWmjjnRoRNX3OEO5hZLyA5xKXdXM+AjTy X-Received: by 2002:a17:907:318b:b0:740:33f2:9e8 with SMTP id xe11-20020a170907318b00b0074033f209e8mr58013103ejb.138.1668092621559; Thu, 10 Nov 2022 07:03:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668092621; cv=none; d=google.com; s=arc-20160816; b=agAx3216Aw3yI3tHw1nbLRczMEEdnIA7Q9lKCMrPphmOCGRLZvW56tlyzA9g87JDv5 wfBmBgmgDAP8iP7RPzb5qPNiNLsPlqOLe9bfxpMYntdkTKHbUY7wxcezbRcJbyWNkNsK uVgAvpm9hoOkbietdUvbM2pTAnSuJpPpzIKL9ej8i0AJXkqX5zSunWtnk0Wj9NWvLAis YLBbshvxf3PsefqhvmqfdZTREUUFuFS+rDQQ3DLg1zD4Itk+84msM2UVL/NBgitgO+ox Ls+cg/YetA2cmzBO7ESJTjB/fjrlyJQ533IQ7VX8b08WaIjsOkaX4YGEzgVJSeYk4z1B 9hkQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=QggOl6oet9gjyrUMq6KLf3FzSdMoYy/LwzCTm6J8+gA=; b=ZMXGoZUrYpHJRPUx9Ce7UM3NYQR+k+Kb49iyfC4YGoe/qJzfQAO2Ep1Dvs9O4uJ08o xwSEkEAjVtSKOC/SfbLEet/MHcsJS3NFiuBCo+2GOTWWmKhFYZjT9BysscVooiwhYRvF TVvbDf7SkCjxjF6G/nC4ANweJyHSb92XxSHNQK9ByeUvxJGwijtWTt99mdTyaBnYtDkU 2nM78nppOnXy4ZXMJ1aHPBFr0yEhy1y748ALqc9aM+Dtv5kNJjuRDMWr+1WQxISXLdRd aPPLfHo/zgoDdmfSHxhgxkDaTPRZA3V7ipe/HFbC448fB3ChsDTU7qhZcnxKOJOfKts9 Hn4A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=ZMS072hG; 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 qf33-20020a1709077f2100b0078e20d9c473si18731081ejc.764.2022.11.10.07.02.41; Thu, 10 Nov 2022 07:03:41 -0800 (PST) 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=ZMS072hG; 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 S230394AbiKJOmu (ORCPT + 92 others); Thu, 10 Nov 2022 09:42:50 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34730 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230238AbiKJOms (ORCPT ); Thu, 10 Nov 2022 09:42:48 -0500 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E60C019288; Thu, 10 Nov 2022 06:42:46 -0800 (PST) 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 83F191FB05; Thu, 10 Nov 2022 14:42:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1668091365; 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=QggOl6oet9gjyrUMq6KLf3FzSdMoYy/LwzCTm6J8+gA=; b=ZMS072hGRT7Bf0y9PM16lWz0Q8PM65nd78eBvUC9sFc0C1kpezgASqxeIDMK8aTmA7+k+1 iYFDCN1izrUXQKtA2wb/YLjQSxzOThg5HHql5Iz3xnt8FvW44zm+MpzNTXDLKfVn/MuY7n c7Q7OCw4Yfo5nWtlAIE6hJ8bG400Igk= 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 365111332F; Thu, 10 Nov 2022 14:42:45 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id zyNJDOUNbWMnLAAAMHmgww (envelope-from ); Thu, 10 Nov 2022 14:42:45 +0000 Date: Thu, 10 Nov 2022 15:42:43 +0100 From: Michal =?iso-8859-1?Q?Koutn=FD?= To: Lu Jialin Cc: Johannes Weiner , Andrew Morton , Michal Hocko , Roman Gushchin , Shakeel Butt , Muchun Song , cgroups@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH] mm/memcontrol.c: drains percpu charge caches in memory.reclaim Message-ID: <20221110144243.GA10562@blackbody.suse.cz> References: <20221110065316.67204-1-lujialin4@huawei.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="5vNYLRcllDrimb99" Content-Disposition: inline In-Reply-To: <20221110065316.67204-1-lujialin4@huawei.com> User-Agent: Mutt/1.10.1 (2018-07-13) X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS autolearn=ham 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 --5vNYLRcllDrimb99 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hello Jialin. On Thu, Nov 10, 2022 at 02:53:16PM +0800, Lu Jialin wrote: > When user use memory.reclaim to reclaim memory, after drain percpu lru > caches, drain percpu charge caches for given memcg stock in the hope > of introducing more evictable pages. Do you have any data on materialization of this hope? IIUC, the stock is useful for batched accounting to page_counter but it doesn't represent real pages. I.e. your change may reduce the page_counter value but it would not release any pages. Or have I missed a way how it helps with the reclaim? Thanks, Michal --5vNYLRcllDrimb99 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- iHUEARYIAB0WIQTrXXag4J0QvXXBmkMkDQmsBEOquQUCY20N4QAKCRAkDQmsBEOq ubBKAQDp1xBK5/DkToOkWZCbNxS9WdDxDYDsi9+ZeCKLncwpHQD9HaNqQZdrxab3 /hyNSLGsED0LyA/3PnNvyOufETMiWQ4= =jyz6 -----END PGP SIGNATURE----- --5vNYLRcllDrimb99--