From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=74.125.82.173 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796267313; b=SC2/QmxuEP6K+fvTKc64pBBI5UZaJkU+EBhwGEOCNGlfKlVZXKBrDlRX9Jcf2YQgeZJQ eNoZ2W3tG6tr+dp8V9xF2wOFpDiYcC384yQe9hHOKl3imRbV5mPTZ7SbTpEA70hb8NyvF W9AwZU+qCZyHHyjG2aPPfjZBkeI5doCtzuTX2EQjgh+UudNozl7A17AcX+EQlRYtwk0hJ 9ibWiXYHUmhpGqRayDgTRVAqxSV6de5x6OErHlVPDlOrv3mqehLnlZmc6y3A14co5zhpW uJ2q+Z7ey4FgpgYkF2eh01hOamq84m2pK9vW+nN3ui9V8d3qjzR1+74p0eqqhnpQSqA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796267313; h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature: X-Forwarded-Encrypted:X-Gm-Message-State:X-Gm-Gg:X-Received:Received: Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; bh=DZaXJZACQSNRLIAu35IOBUCiuDWwoVOGrMzUkUxZW9E=; b=LBXeD1dPsx4kcysW3Rd0ys/OTScZuJF6/mQ1lAq8baIy5pZaYmv75rZF9C9dmcHIRirv 38terhc8Y2mHRchysWXW8tP/b3ZXyYFhWDN3gM/MY3UZSD/6NTrYPrCP+OrcoYwTOJP+b vs8MrQT+OhZbUBFQiexy4hFViQv3yuUCmE2Cy7W2KzxWP/Dqn8AQWiFUXY3VFTbxR1SIt CkQs5M8w9WOlhSDydWSZyLvK25IxNs1WI/SJa69KxeHViSlHu/ttgHq7xvhVA1k6u6qU7 DBdVtzSSF4BZE2RRJd4KG9adhMHG7eCbu6ZQKiOay8yK9b9qiPt9l+JXnQOJhcaDDDg== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=chromium.org; spf=pass smtp.mailfrom=chromium.org; dkim=pass header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=BjFKvk5+; arc=none smtp.remote-ip=74.125.82.173 Received: from mail-dy1-f173.google.com (mail-dy1-f173.google.com [74.125.82.173]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 529D960A2636 for ; Thu, 3 Dec 2026 03:08:33 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 529D960A2636 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=chromium.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key, unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=BjFKvk5+ Received: by mail-dy1-f173.google.com with SMTP id 5a478bee46e88-386c71feeeaso11847327eec.0 for ; Wed, 02 Dec 2026 19:08:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1796267312; x=1796872112; darn=vger.kernel.org; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:from:to:cc:subject :date:message-id:reply-to:content-type; bh=DZaXJZACQSNRLIAu35IOBUCiuDWwoVOGrMzUkUxZW9E=; b=BjFKvk5+P7i186WoJafH609mUSKyZc6D9ljy+Kx9wnQ5rYnMGgVyzn0z7FoVImB+Tu t4TdKTmvOD1Si+XjPrEXptZbuXfGieWN9Cemcv2vN8mZUuumtwmhJjAJgAgrLJl8/kgp lBcwWcYSPWFBCWjnJYFYJoaO9CNljngEEN37w= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796267312; x=1796872112; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=DZaXJZACQSNRLIAu35IOBUCiuDWwoVOGrMzUkUxZW9E=; b=EgCgMJtC2HRs2AWL/F7IIjYpPd4DtY7ouY0WXhw45tJzCmf9uM2W3nZayb3MQRXd0o romgEloL4j8siyYw7m9AxH8SV2eEp+ypQ5++CpJe8lV/Kfni7/5Mluw7omEg8b4bLWxk mGh9sCLFCIVDE84Rv97uhHu98PD/OF0KxYXQZGwpG/+voC/ex8iqFsjXXzVFFv1mE0gR cHrzY+0r0wjw88id0ZwO1m5OGvrJtGDv+vLGrYXsKqAk6AyMykpc6Vyy15cGhTv5HSrr uuFezkHDV78wyVAYaan44+S/XLAigQzNWWiVpOKKTgt7DrZKUSNwGIhXhmVnCuAcif3Z pJZg== X-Forwarded-Encrypted: i=1; AL+hErEFDWWXykVHaaHNnzqJouHI0qwHgLT10Pimt8gfJL0fD4aDebWYdcJ60gVbIKgeUfbMHvpfCxd17JU5V+E=@vger.kernel.org X-Gm-Message-State: APuU4Z967/VlwQn8SI2/aJPCeXkbZvXgsL2PJVA182r4tec6GIEczdec aLFldRVPgUjkbWgnybWMGRjRvfgyxfkfdWdrgOdCyChXBwGRZRvBAmxcm/Z1bfq4ng== X-Gm-Gg: AZFdTZdDrnWxyc9ACwsEyFaDcH7Spy+BMFOXEU84y0Vz9Dxa01ZaNWanQrXqd7VObo3 E8PZN2fqSQzlT2EzHGRixYqrOiHi73nosZxXN/1s6D7BlrwM0zjP8ffpIVjxoZLY0EVNhB0nqNV eDefddJWYY0iDZFe4qsfgYeC8sgTB1/86a7qOmevo/mrwOe15Hqd16feH+Byp4U7nkrJSXJ9Mof G5etRvK/2xt2HcBsF6sQswc2pdxUUednwTg6HZNTPWu61G6PO6f7pF2U3EVvm2nGSrUzfWEIDQP Ubn5HJXMl3j4Et+ofRkPlitNT57yKyZ7wlZeSg9663YP7B+shpq8zuHsVEzDF4H+EX+fkz6z5I8 PZ4Rm1AHgumPhxwKRvlf28BnEqaLmjatZjkASb2TE4cPDw4TirtUvnK1wk44mN86VZvmEahf3Am +8prpO485vDCRyy6D1ZG1hKy3wHMoQLW//PhyoUic6AYrpMcpZodXKPutm5MFVNDxjhzN6RaQBf asWE4qBRSAn3SSc/37TB5BSdtZeUqbZuRQF73LaXMfqOBRVLUCiwpsMqNQEXLJb9c72csOv/ul4 VpEibp4aLpjNmIQm2HW5NGeqxXbXaccyzCeTJd18vnk0YXol+JPSe0VcN/IGIoBwZNRY X-Received: by 2002:a05:7300:10e:b0:386:cd61:23b2 with SMTP id 5a478bee46e88-386cd6124c8mr26902478eec.40.1796267312280; Wed, 02 Dec 2026 19:08:32 -0800 (PST) Received: from google.com ([2a00:79e0:2031:6:e18c:e957:aa04:7114]) by smtp.gmail.com with ESMTPSA id 5a478bee46e88-385672c6f31sm121090501eec.15.2026.12.02.19.08.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 02 Dec 2026 19:08:31 -0800 (PST) Date: Thu, 3 Dec 2026 12:08:27 +0900 From: Sergey Senozhatsky To: Barry Song Cc: Sergey Senozhatsky , Chris Wiseman , Andrew Morton , Minchan Kim , Johannes Weiner , Yosry Ahmed , Nhat Pham , Chengming Zhou , Xueyuan Chen , Xueyuan Chen , Brian Geffon , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm/zsmalloc: remove shrinker Message-ID: References: <18ed2967f99a2eff.3137322e32332e3235332e313736.2c2157.0000sendgmr@google.com> X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Hi Barry, On (26/12/02 18:21), Barry Song wrote: > > > Hi Chris, Xueyuan and all, > > > > > > Thanks for the patch and the report. Just curious, do we need > > > userspace-triggered proactive compaction > > > > Wouldn't hurt to keep it around, I guess. But maybe can NOOP it > > in the future (removing zram device attributes is a bit difficult, > > we usually give around 3-5 years of deprecation cooldown period > > before removal.) > > Hi Sergey, > > Thanks for your reply. Sorry, I might not have expressed my question > clearly. Here is what I meant: Oh, my bad! > We used to have automatic compaction through the shrinker. Now that > we have removed it, do we still expect compaction to be triggered, > either automatically or manually by writing to the zram sysfs > attribute? > > I know the changelog already says: > > " Testing on ARM64 QEMU shows that removing the shrinker eliminates > mid-swap compaction churn without increasing active pool memory > usage for either zram or zswap." > > But what about periods when swap-out is not active? Would compaction > still be beneficial in those cases? I suppose compaction will be beneficial after a huge app swap-in, e.g. bringing back a web browser with (usual) million tabs. Or after a huge app kill/termination, if the app had swap presence. Both of these release memory from zsmalloc and create fragmentation, so we might benefit from doing a de-fragmentation.