io-uring.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chenliang Li <cliang01.li@samsung.com>
To: axboe@kernel.dk
Cc: asml.silence@gmail.com, cliang01.li@samsung.com,
	gost.dev@samsung.com, io-uring@vger.kernel.org,
	joshi.k@samsung.com, kundan.kumar@samsung.com,
	peiwei.li@samsung.com
Subject: Re: [PATCH v2 0/4] io_uring/rsrc: coalescing multi-hugepage registered buffers
Date: Mon, 13 May 2024 10:01:49 +0800	[thread overview]
Message-ID: <20240513020149.492727-1-cliang01.li@samsung.com> (raw)
In-Reply-To: <0fa012c7-427c-4791-95be-7ba72cfe593a@kernel.dk>

On 2024-05-11 16:43 Jens Axboe wrote:
> On 5/10/24 11:52 PM, Chenliang Li wrote:
>> Registered buffers are stored and processed in the form of bvec array,
>> each bvec element typically points to a PAGE_SIZE page but can also work
>> with hugepages. Specifically, a buffer consisting of a hugepage is
>> coalesced to use only one hugepage bvec entry during registration.
>> This coalescing feature helps to save both the space and DMA-mapping time.
>> 
>> However, currently the coalescing feature doesn't work for multi-hugepage
>> buffers. For a buffer with several 2M hugepages, we still split it into
>> thousands of 4K page bvec entries while in fact, we can just use a
>> handful of hugepage bvecs.
>> 
>> This patch series enables coalescing registered buffers with more than
>> one hugepages. It optimizes the DMA-mapping time and saves memory for
>> these kind of buffers.

> This series looks much better. Do you have a stand-alone test case
> for this? We should have that in liburing. Then we can also augment it
> with edge cases to ensure this is all safe and sound.

Thanks! Yes, I have a liburing test case, will send it as a patch in V3.

      parent reply	other threads:[~2024-05-13  2:18 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20240511055242epcas5p46612dde17997c140232207540e789a2e@epcas5p4.samsung.com>
2024-05-11  5:52 ` [PATCH v2 0/4] io_uring/rsrc: coalescing multi-hugepage registered buffers Chenliang Li
     [not found]   ` <CGME20240511055243epcas5p291fc5f72baf211a79475ec36682e170d@epcas5p2.samsung.com>
2024-05-11  5:52     ` [PATCH v2 1/4] io_uring/rsrc: add hugepage buffer coalesce helpers Chenliang Li
2024-05-11 16:43       ` Jens Axboe
     [not found]   ` <CGME20240511055245epcas5p407cdbc005fb5f0fe2d9bbb8da423ff28@epcas5p4.samsung.com>
2024-05-11  5:52     ` [PATCH v2 2/4] io_uring/rsrc: store folio shift and mask into imu Chenliang Li
     [not found]   ` <CGME20240511055247epcas5p2a54e23b6dddd11dda962733d259a10af@epcas5p2.samsung.com>
2024-05-11  5:52     ` [PATCH v2 3/4] io_uring/rsrc: add init and account functions for coalesced imus Chenliang Li
2024-05-11 16:48       ` Jens Axboe
     [not found]         ` <CGME20240513021656epcas5p2367b442e02b07e6405b857f98a4eff44@epcas5p2.samsung.com>
2024-05-13  2:16           ` Chenliang Li
     [not found]   ` <CGME20240511055248epcas5p287b7dfdab3162033744badc71fd084e1@epcas5p2.samsung.com>
2024-05-11  5:52     ` [PATCH v2 4/4] io_uring/rsrc: enable multi-hugepage buffer coalescing Chenliang Li
2024-05-11 16:49       ` Jens Axboe
2024-05-11 16:43   ` [PATCH v2 0/4] io_uring/rsrc: coalescing multi-hugepage registered buffers Jens Axboe
     [not found]     ` <CGME20240513020155epcas5p23699782b97749bfcce0511ce5378df3c@epcas5p2.samsung.com>
2024-05-13  2:01       ` Chenliang Li [this message]

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=20240513020149.492727-1-cliang01.li@samsung.com \
    --to=cliang01.li@samsung.com \
    --cc=asml.silence@gmail.com \
    --cc=axboe@kernel.dk \
    --cc=gost.dev@samsung.com \
    --cc=io-uring@vger.kernel.org \
    --cc=joshi.k@samsung.com \
    --cc=kundan.kumar@samsung.com \
    --cc=peiwei.li@samsung.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;
as well as URLs for NNTP newsgroup(s).