linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: kbusch@kernel.org
To: linux-kernel@vger.kernel.org, linux-mm@kvack.org
Cc: willy@infradead.org, kernel-team@fb.com, Keith Busch <kbusch@kernel.org>
Subject: [PATCH 0/2] dmapool performance enhancements
Date: Thu, 28 Apr 2022 14:27:12 -0600	[thread overview]
Message-ID: <20220428202714.17630-1-kbusch@kernel.org> (raw)

From: Keith Busch <kbusch@kernel.org>

Allocating and freeing blocks from the dmapool iterates a list of all
allocated pages. We can save time removing the per-alloc/free list
traversal for a constant time lookup, so this series does that.

Compared to current kernel, perf record from running io_uring benchmarks
on nvme reports dma_pool_alloc() cost reduction cut in half from 0.81% to
0.41%.

Keith Busch (2):
  mm/dmapool: replace linked list with xarray
  mm/dmapool: link blocks across pages

 mm/dmapool.c | 107 +++++++++++++++++++++++++++------------------------
 1 file changed, 56 insertions(+), 51 deletions(-)

-- 
2.30.2



             reply	other threads:[~2022-04-28 20:27 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-28 20:27 kbusch [this message]
2022-04-28 20:27 ` [PATCH 1/2] mm/dmapool: replace linked list with xarray kbusch
2022-04-28 21:59   ` Matthew Wilcox
2022-04-29  1:41     ` Keith Busch
2022-04-28 20:27 ` [PATCH 2/2] mm/dmapool: link blocks across pages kbusch
2022-05-27 19:35 ` [PATCH 0/2] dmapool performance enhancements Tony Battersby
2022-05-27 21:01   ` Keith Busch

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=20220428202714.17630-1-kbusch@kernel.org \
    --to=kbusch@kernel.org \
    --cc=kernel-team@fb.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=willy@infradead.org \
    /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