From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=74.125.82.180 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796353653; b=WR1QyPcx5ywxi/Ni7ArN/KG5JkxQJrMjXvbZw8BoMOTI9ZJLrJfB4lbsMhetdRDyrZgl ahGdDvGvzo1vFCXay8NWqm7bp9/Da4hUXG77nhHROjVIw1l4tW0I/Yo+U115SmDJfciMI yWInTjaWrh+e3PxJLStk+g3aoMi9EAW02ePoO1DIMtpn0Ma1mqaH/I5M0imDHe8N/JdYg xBbJsKMlqzBBW+m1p4gRWOstyxdFpJODgfLL1y9PwE6MRSqHhs96hwhnStFLSelzLd4LL uAN0dlVCu39X6Od4RcW4tnEETPAhUM4tB0fEPJPqsG99+MQWJQ+aqvECyINUIbaLIgQ== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796353653; 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=NqwyNX3n6I4CrrUkHGhE4+AJA2CTaoHex1bIbdlZVxo=; b=N2ZuaLocSwz04W/u+xW64kpFJFyHrxLDdbWJMMkQ/9DFj//6xFrfpgYqAM3auyZAA0jc rM48LGIGd8olIFRgZt9rflo0wcX3aaeYgVVFNc8/7h+Bm0TF65uVtm8FX3ySHSTLp5BUp ZFkaSM3G2O2X7bjBsdwv+Yp6HOPTv0FFrc+qZRA1/F3w1HS1HQKRsypNbDIQxfjnlpuXB UOOXKoV6P19PUVHlAP85BghrjDN8ayCHgclcQTQpYw3AlvpxWO5wvUIDKLYNANiinHvsg mcBMEvM4lQDxsZzPXz7diHjji/CpiDly5ASpm2hy+T0lfBEf4nmZ5ztMoTOQB9tk+dQ== 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=X8EAL6nC; arc=none smtp.remote-ip=74.125.82.180 Received: from mail-dy1-f180.google.com (mail-dy1-f180.google.com [74.125.82.180]) (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 74082606A322 for ; Fri, 4 Dec 2026 03:07:33 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 74082606A322 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=X8EAL6nC Received: by mail-dy1-f180.google.com with SMTP id 5a478bee46e88-385c497bf94so979887eec.1 for ; Thu, 03 Dec 2026 19:07:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1796353652; x=1796958452; 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=NqwyNX3n6I4CrrUkHGhE4+AJA2CTaoHex1bIbdlZVxo=; b=X8EAL6nCQgrsRckCOTHMCuFTeHgXyI+03kkP6i0N4iv8q3bd07aAaLHOgexR+vFVxv +zEM3uQe+daGN3NdFVTkC2kS2IAWQZM5llzWOy/Bpc/rH8Gi9eoaRDrlqQFrOR9nhD1b S4VgqFYQ2Gz6cfaylTeeHEaCHM1//4sDK4zgI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796353652; x=1796958452; 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=NqwyNX3n6I4CrrUkHGhE4+AJA2CTaoHex1bIbdlZVxo=; b=GOtrjAKQ2j/5qZAsoRFsHEsEmykRJcwYoDoW+M8giaRfM/trmyt8pmhGmjZK37+bTR gam09bSGOmoXfHfyjQddvrqSy79CPpVMLb90c2EBGqyXgKTIlHLFuKsKhBLv/36Y8jbf BccQKruGSV1TTu+1v+bYAOd01Sj/lgxwivVi/gQRxojJV2VnlhHCf2XjiWgeBN3BXpwB OKY060OtydknalPJYvzWux3mXd05cBt9d8TLqlyfj0q+MI0DHq5wCTfSdI2zIW5Fvhbz XwADn8xz6IGt0pWm/lU+InemrlQ+qQSi64qKnQsVzmeblOzu0edWtXiP5aZGnjxM68uC QB3g== X-Forwarded-Encrypted: i=1; AL+hErEw0BW+DUT22PMc/L3NqTdyqigVl1liN5CjqwRvYnd6bhEZBi8i/zcLscaa7dXIZd4gqQl3aDiKQaY1AmE=@vger.kernel.org X-Gm-Message-State: APuU4Z+6M3XT55sp2P2wCyFn4qHJsLQRyix6e/dRhHtpDnhFq2uevWtB PqrPcrwlaHrMUDQlU07UXN1IirkNKbvkxE/exT5AFdQGCAJ8Vdh1xKfFQn4AxZP1/Q== X-Gm-Gg: AZFdTZcKh/mki7XVNNbhCjG6vp8VmE8tEzakhbsyeU9ar4ORUL8d+3IaOkiEnAD7WMU u4Ex5/CTRJOQY9YxpSplJIkc3uRL/7KIyyusRdcYraVE1VZoo2QIZG/rQUUR1aHqlL9wRQ0DUiG pw5eNgZElOAdaWay+O02brSC2Ja0W53GwKWnxk4W0AnP5FaEXGeHpxEzKb023P+2aniTuSpQri7 PoUqy7KYz1iIXDc/o5ZKofz4q/h+uqCMspFWn8vw0eGd4+htsJiB56JJAfaMmZYYJDP38ZsEHPD rP8SODLpHw+CU+yNBHzUAO1vSUC5T1FSiEUIYle4mdNyD9yijYJIYQ+bpp3GvlSce9Zppun25Yh pN+MHYLSutnRglPaKe/47anwAI3B9nFSvcJp6/sdHcF594VJ/BO0IjAmYzK/7dh/QNUpC8D8F2W LlDTFm2CQ81CHSF/onwvjb/7cJoV53kpR0BqPY6OxAe080mh4iH47FodoLKTESNOpOt3WzRC3dR vXbbKHVoKcUbYukaXBHFUUvKYpW2HIlNjculhB2TzJWS8DuK88MR0QTRvkqri6+aSMpYEQ7KISm JQ3GSluYt3Xss25i5nRfJrbSDCbrWeYkhgYho/9l9+3FxRVW/HrQG7rt9ejDFPOQap9nTJHq4uk Sg6CMIgxCxgkKOow= X-Received: by 2002:a05:7300:cf90:b0:387:44b0:fa6a with SMTP id 5a478bee46e88-3875224319cmr735464eec.42.1796353652475; Thu, 03 Dec 2026 19:07:32 -0800 (PST) Received: from google.com ([2a00:79e0:2031:6:b1d8:8dc2:95bf:66b9]) by smtp.gmail.com with ESMTPSA id 5a478bee46e88-38752204591sm2444758eec.21.2026.12.03.19.07.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 03 Dec 2026 19:07:31 -0800 (PST) Date: Fri, 4 Dec 2026 12:07:27 +0900 From: Sergey Senozhatsky To: Yosry Ahmed Cc: Sergey Senozhatsky , Chris Wiseman , Barry Song , Nanzhe Zhao , Andrew Morton , Minchan Kim , Johannes Weiner , 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: <18eda4bfd6c242a5.3137322e32332e3235332e313736.202733.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: On (26/12/03 08:16), Yosry Ahmed wrote: > > > 3. The 10-second timer doesn't know about memory pressure, whereas the > > > shrinker ran when reclaim wanted pages. Not a blocker, just the first > > > thing I'd watch if the Pixel numbers don't come back down. > > > > So that 10 seconds cooldown is there because those slot-free calls don't > > come alone, usually. It's more likely to be a burst of slot-free's and > > 10 seconds wait kind of tries to space them (burst and compaction) out. > > 10 seconds could be too long or too short, and it can hit another > slot-free burst. What if we kick the deferred work by a smaller amount > every time instead of a fixed "10 seconds after first slot-free"? > Basically, if (let's say) 1 second passes with no slot freeing, then > the async compaction runs and checks the threshold? 10 seconds static timeout was for simplicity, in current iteration I'm mirroring (well, at least I think that's what I'm doing) mm/compaction.c exponential backoff logic. > Also, does compact_threshold belong in zsmalloc not zram, so that it > can also be used for zswap? I also wonder if the proactive compaction > zram interface should be deprecated in favor of just tuning the > threshold to have a single mechanism for zsmalloc compaction. Sure, zram compaction was an initial solution, it has moved to zsmalloc since then. > > > Andrew, please drop mm-zsmalloc-remove-shrinker.patch from mm-new for > > > now. Once we have the Pixel 6 numbers, we can send a 2-patch series > > > with Sergey's patch first and the shrinker removal second so git bisect > > > doesn't hit a regressing commit. Sergey, happy to carry your patch or > > > rebase mine on top of yours, whichever you prefer. > > > > I think your patch will go in as is, no need to rebase, the remaining > > work will stack on top of it. I guess we want shrinker replacement, > > just need to figure out what do we replace it with. > > Might be better to put it at the end so that there's no intermittent > regressions. Not a big deal tho. Yeah, probably not a big deal.