From: Fabiano Rosas <farosas@suse.de>
To: Bin Guo <guobin@linux.alibaba.com>, qemu-devel@nongnu.org
Cc: peterx@redhat.com, pierrick.bouvier@oss.qualcomm.com
Subject: Re: [PATCH 1/2] docs/migration: document that postcopy can be used with multifd
Date: Tue, 22 Sep 2026 11:44:03 -0300 [thread overview]
Message-ID: <87se319wi4.fsf@suse.de> (raw)
In-Reply-To: <20260915063719.89031-2-guobin@linux.alibaba.com>
Bin Guo <guobin@linux.alibaba.com> writes:
> Since commit e27418861288 ("migration: enable multifd and postcopy
> together") in the 10.1 release, the multifd and postcopy-ram capabilities
> are no longer mutually exclusive, but the postcopy documentation does not
> mention multifd at all, leaving users unaware that the two features can be
> combined.
>
> Add a short section describing how they interact: multifd carries the
> pages of the precopy phase, the channels are flushed and synced before the
> switchover (because loading a page in a multifd receive thread is not
> atomic with regard to a running vCPU), and the postcopy phase itself does
> not use the multifd channels.
>
> Signed-off-by: Bin Guo <guobin@linux.alibaba.com>
> ---
> docs/devel/migration/postcopy.rst | 26 ++++++++++++++++++++++++++
> 1 file changed, 26 insertions(+)
>
> diff --git a/docs/devel/migration/postcopy.rst b/docs/devel/migration/postcopy.rst
> index e319388d8f..570a3a1ce6 100644
> --- a/docs/devel/migration/postcopy.rst
> +++ b/docs/devel/migration/postcopy.rst
> @@ -294,6 +294,32 @@ the background migration channel. Anyone who cares about latencies of page
> faults during a postcopy migration should enable this feature. By default,
> it's not enabled.
>
> +Postcopy with multifd
> +---------------------
> +
> +The ``multifd`` capability can be enabled together with ``postcopy-ram``
> +since the 10.1 QEMU release. The two features apply to different phases of
> +the migration:
> +
> + - During the precopy phase, guest pages are sent over the multifd channels
> + as usual, so the initial RAM transfer can use all of them.
> +
> + - Just before switching to postcopy, the source flushes and syncs the
> + multifd channels. This guarantees that all the pages already queued on
> + those channels are loaded on the destination *before* the destination
> + CPUs are started, which is required because loading a page in a multifd
> + receive thread is not atomic with regard to a running vCPU.
> +
> + - During the postcopy phase the multifd channels are no longer used for
> + guest pages. Both the background stream and the pages requested by the
> + destination go through the background migration channel instead, or
> + through the preempt channel for the requested pages when postcopy
> + preemption is enabled.
> +
> +Consequently, multifd only speeds up the precopy phase of a postcopy
> +migration. The bandwidth available once postcopy has started is the same as
> +without multifd.
> +
> Postcopy blocktime statistics
> -----------------------------
Looks good to me, I'll wait a bit to allow Peter to comment.
Acked-by: Fabiano Rosas <farosas@suse.de>
next prev parent reply other threads:[~2026-09-22 14:45 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-15 6:37 [PATCH 0/2] migration/postcopy: shared-fault accounting and multifd docs Bin Guo
2026-09-15 6:37 ` [PATCH 1/2] docs/migration: document that postcopy can be used with multifd Bin Guo
2026-09-22 14:44 ` Fabiano Rosas [this message]
2026-09-22 17:29 ` Peter Xu
2026-09-15 6:37 ` [PATCH 2/2] migration/postcopy: account faults taken by memory sharing processes Bin Guo
2026-09-22 17:55 ` Peter Xu
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=87se319wi4.fsf@suse.de \
--to=farosas@suse.de \
--cc=guobin@linux.alibaba.com \
--cc=peterx@redhat.com \
--cc=pierrick.bouvier@oss.qualcomm.com \
--cc=qemu-devel@nongnu.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.