linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Nhat Pham <nphamcs@gmail.com>
To: Yosry Ahmed <yosryahmed@google.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>,
	akpm@linux-foundation.org, shakeelb@google.com,
	 linux-mm@kvack.org, kernel-team@meta.com,
	linux-kernel@vger.kernel.org,  flintglass@gmail.com
Subject: Re: [PATCH 1/2] zswap: implement a second chance algorithm for dynamic zswap shrinker
Date: Tue, 30 Jul 2024 14:40:42 -0700	[thread overview]
Message-ID: <CAKEwX=Mzzs0kU4Fmw-hiyMT_6m37N6i=xWaEgZoCN+RAx6McSQ@mail.gmail.com> (raw)
In-Reply-To: <CAJD7tka1tPA=qGFJcf4n1MM20A4WoL0cA28jDcyoc0y+48+0bw@mail.gmail.com>

On Tue, Jul 30, 2024 at 11:46 AM Yosry Ahmed <yosryahmed@google.com> wrote:
>
>
> I still think the nr_deferred handling in the shrinker framework does
> not seem compatible with zswap. Entries could be double counted, and
> previously counted entries could go away during swapins. Unless I am
> missing something, it seems like the scanning can be arbitrary, and
> not truly proportional to the reclaim priority and zswap LRUs size.

We can do some investigation by the side. I did find the trace point
that collects deferred numbers, maybe that can illustrate the problem?

It'd be an orthogonal issue though. I don't think fixing the
nr_deferred part would be enough to handle the various cases Johannes
pointed out.


  reply	other threads:[~2024-07-30 21:40 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-25 23:28 [PATCH 0/2] improving dynamic zswap shrinker protection scheme Nhat Pham
2024-07-25 23:28 ` [PATCH 1/2] zswap: implement a second chance algorithm for dynamic zswap shrinker Nhat Pham
2024-07-26 21:58   ` Yosry Ahmed
2024-07-29 23:07     ` Nhat Pham
2024-07-30  0:07       ` Nhat Pham
2024-07-30  3:39     ` Johannes Weiner
2024-07-30  6:23       ` Nhat Pham
2024-07-30 18:46       ` Yosry Ahmed
2024-07-30 21:40         ` Nhat Pham [this message]
2024-07-30 22:04         ` Nhat Pham
2024-07-25 23:28 ` [PATCH 2/2] zswap: increment swapin count for non-pivot swapped in pages Nhat Pham

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAKEwX=Mzzs0kU4Fmw-hiyMT_6m37N6i=xWaEgZoCN+RAx6McSQ@mail.gmail.com' \
    --to=nphamcs@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=flintglass@gmail.com \
    --cc=hannes@cmpxchg.org \
    --cc=kernel-team@meta.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=shakeelb@google.com \
    --cc=yosryahmed@google.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox