Skip to content

migration: Make multifd use only one write on the send path

Juan Quintela qemu-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest9 of 11 patches 7 repliesIn review

9 of 11 patches are in this archive. The cover letter announces 11.

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/11migration: Remove is_zero_range()migration/ram.c+2 -71 reply
2/11dump: Remove is_zero_page()dump/dump.c+1 -92 replies
3/11multifd: Fill offset and block for receptionmigration/multifd.c+2 -02 replies
4/11multifd: Make zstd compression method not use iovsmigration/multifd-zstd.c+9 -90 replies
5/11multifd: Make zlib compression method not use iovsmigration/multifd-zlib.c+9 -80 replies
6/11migration: Move iov from pages to paramsmigration/multifd.c migration/multifd.h+27 -112 replies
7/11multifd: Make zlib use iov'smigration/multifd-zlib.c+4 -40 replies
8/11multifd: Make zstd use iov'smigration/multifd-zstd.c+4 -40 replies
9/11multifd: Remove send_write() methodmigration/multifd-zlib.c migration/multifd-zstd.c migration/multifd.c +1 more+2 -540 replies

Reviews trailers per patch

2 of 9 patches have a Reviewed-by or Acked-by.

PatchRichard HendersonMarc-André Lureau
1/11R-b
2/11R-b R-b
3/11
4/11
5/11
6/11
7/11
8/11
9/11

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 00/11] migration: Make multifd use only one write on the send path

Hi

Right now, multifd does a write() for the header and a writev() for each group of pages. Simplify it so we send the header as another member of the IOV.

Once there, I got several simplifications:
* is_zero_range() was used only once, just use its body.
* same with is_zero_page().
* Be consintent and use offset insed the ramblock everywhere.
* Now that we have the offsets of the ramblock, we can drop the iov.
* Now that nothing uses iov's except NOCOMP method, move the iovs from pages to methods.
* Now we can use iov's with a single field for zlib/zstd.
* send_write() method is the same in all the implementaitons, so use it directly.
* Now, we can use a single writev() to write everything.

ToDo: Move zero page detection to the multifd thrteads.

With RAM in the Terabytes size, the detection of the zero page takes too much time on the main thread.

Last patch on the series removes the detection of zero pages in the main thread for multifd. In the next series post, I will add how to detect the zero pages and send them on multifd channels.

Please review.

Later, Juan.

Juan Quintela (11):
migration: Remove is_zero_range()
dump: Remove is_zero_page()
multifd: Fill offset and block for reception
multifd: Make zstd compression method not use iovs
multifd: Make zlib compression method not use iovs
migration: Move iov from pages to params
multifd: Make zlib use iov's
multifd: Make zstd use iov's
multifd: Remove send_write() method
multifd: Use a single writev on the send side
migration: Use multifd before we check for the zero page

 migration/multifd.h      | 10 ++++---
 dump/dump.c              | 10 +------
 migration/multifd-zlib.c | 40 ++++++++------------------
 migration/multifd-zstd.c | 41 ++++++++------------------
 migration/multifd.c      | 62 ++++++++++++++++++----------------------
 migration/ram.c          | 31 +++++++++-----------
 6 files changed, 72 insertions(+), 122 deletions(-)
Signature · 1 line
2.33.1