Re: [PATCH v2 1/2] zsmalloc: free a zspage's pages in one batch

From: Sergey Senozhatsky

Date: Tue Nov 24 2026 - 22:58:22 EST


On (26/11/24 16:16), Nhat Pham wrote:
[..]
> [...]
>
> > ---
> > + zpdesc = get_first_zpdesc(zspage);
> > + if (get_next_zpdesc(zpdesc)) {
> > + free_page_chain(zpdesc);
> > + } else {
> > + /* Single-page zspage, e.g. a huge object: nothing to batch */
>
> I wonder if it's worth keeping the old logic for incompressible case.

It does appear to be worth it, it's visible in profiles. Batching comes
as a win for multi-page zspages.