linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: David Rientjes <rientjes@google.com>
To: Jianfeng Wang <jianfeng.w.wang@oracle.com>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, vbabka@suse.cz,
	 cl@linux.com, akpm@linux-foundation.org, penberg@kernel.org
Subject: Re: [PATCH v3 2/2] slub: use count_partial_free_approx() in slab_out_of_memory()
Date: Fri, 19 Apr 2024 17:18:44 -0700 (PDT)	[thread overview]
Message-ID: <3f53b749-46b3-d1a6-8984-c8a3fc9481ac@google.com> (raw)
In-Reply-To: <20240419175611.47413-3-jianfeng.w.wang@oracle.com>

On Fri, 19 Apr 2024, Jianfeng Wang wrote:

> slab_out_of_memory() uses count_partial() to get the exact count
> of free objects for each node. As it may get called in the slab
> allocation path, count_partial_free_approx() can be used to avoid
> the risk and overhead of traversing a long partial slab list.
> 
> At the same time, show_slab_objects() still uses count_partial().
> Thus, slub users can still have the option to access the exact
> count of objects via sysfs if the overhead is acceptable to them.
> 
> Signed-off-by: Jianfeng Wang <jianfeng.w.wang@oracle.com>

Acked-by: David Rientjes <rientjes@google.com>


  reply	other threads:[~2024-04-20  0:18 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-19 17:56 [PATCH v3 0/2] slub: introduce count_partial_free_approx() Jianfeng Wang
2024-04-19 17:56 ` [PATCH v3 1/2] " Jianfeng Wang
2024-04-20  0:18   ` David Rientjes
2024-04-22  7:49     ` Vlastimil Babka
2024-04-19 17:56 ` [PATCH v3 2/2] slub: use count_partial_free_approx() in slab_out_of_memory() Jianfeng Wang
2024-04-20  0:18   ` David Rientjes [this message]
2024-04-22  7:56 ` [PATCH v3 0/2] slub: introduce count_partial_free_approx() Vlastimil Babka

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=3f53b749-46b3-d1a6-8984-c8a3fc9481ac@google.com \
    --to=rientjes@google.com \
    --cc=akpm@linux-foundation.org \
    --cc=cl@linux.com \
    --cc=jianfeng.w.wang@oracle.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=penberg@kernel.org \
    --cc=vbabka@suse.cz \
    /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