[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v4 11/16] PoC: libs/guest: use foreign copy during migration


  • To: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
  • From: Frediano Ziglio <freddy77@xxxxxxxxx>
  • Date: Thu, 4 Jun 2026 15:51:26 +0100
  • Arc-authentication-results: i=1; mx.google.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=0zEUd0XlamqIYnkUv7mQ37REhnYyl5NfHmJhFAJoMCY=; fh=YXyOrzbbuBMjB1laPSTTaglkJ9ItuXSXF5B6orWbM3Y=; b=CnhCyMSZkPYQ5Q1URbhrR3ccgNr2kdWygsJmUWMz4BQjUSojYgo2CrDoXKp5ZTZCUK Zx/rl6EwuPqnXlBGoqdwoJ2XNeorqeAGhd8C/CJG9Ahrs5LGYjCbAMnACKVtx3nd44sb OHfc7XcjseQz93O+uWFbQH4MUEGCnDPPsNsNrxTqdKtGSBrRsBXTQ4yzofZe20GaMYgh tnKCInQ3DRGE1ZyV+5GfvIOoZjQ6kASbLdGInpDpFVmysQdHnh1UmLsqy+E8fpOUMV5y lPQ1ORrnbdH2NVS5P5mPRHzQBU3Ay97w4gHyzmU8SSzDQLmErtKamP0j4Lcj6w4CqaLd CzAQ==; darn=lists.xenproject.org
  • Arc-seal: i=1; a=rsa-sha256; t=1780584698; cv=none; d=google.com; s=arc-20240605; b=NNSpuyi3TirAZhchCQyKVzlKn8C0R3526ubpVim2RmpAXjHijGacLHgnxwJBZnUOOc M+SezsI2C3sn6PVBBOGWK4g6FVaqu+kC1x33uOlha0g814ZhSLfqYM712IiFP92QQFfv mm2Atmx5qcE9kH9nJY+xgh+mJhoKfBAaCBLT3M28ADHBhvsUa58pY/f5gFOuQrm2OinB 6D+AM8bFyHCtSP9bzBsw7/xdNSNxxRB+IT51VvfKKFeuEPhpYfggpFljozjGOBLxf0KB YGw8jZ3V+tKvBhEQ0dB5DfSrZWLFFJhY2gCK00q1ugJDo+ig8v+bHyeQaFM40XsPH/Ra N80w==
  • Authentication-results: eu.smtp.expurgate.cloud; dkim=pass header.s=20251104 header.d=gmail.com header.i="@gmail.com" header.h="Content-Transfer-Encoding:Cc:To:Subject:Message-ID:Date:From:In-Reply-To:References:MIME-Version"
  • Cc: xen-devel@xxxxxxxxxxxxxxxxxxxx, Edwin Török <edwin.torok@xxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Teddy Astie <teddy.astie@xxxxxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>, Juergen Gross <jgross@xxxxxxxx>, Frediano Ziglio <frediano.ziglio@xxxxxxxxxx>
  • Delivery-date: Thu, 04 Jun 2026 14:52:18 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On Wed, 3 Jun 2026 at 15:09, Andrew Cooper <andrew.cooper3@xxxxxxxxxx> wrote:
>
> On 03/06/2026 2:05 pm, Frediano Ziglio wrote:
> > From: Edwin Török <edwin.torok@xxxxxxxxxx>
> >
> > ministat confirms the improvement:
> >
> > ```
> > x baseline
> > + foreigncopy
> >     N           Min           Max        Median           Avg        Stddev
> > x  20     1.1306997     1.1447931     1.1356569     1.1365742   0.003242175
> > +  20     0.4311504    0.44180303    0.43616705    0.43600089  0.0031094689
> > Difference at 95.0% confidence
> >       -0.700573 +/- 0.00203311
> >       -61.639% +/- 0.133355%
> >       (Student's t, pooled s = 0.00317652)
> > ```
> >
> > The tests pass too, which means that it has correctly migrated all guest
> > memory.
> >
> > Frediano: This PoC was adapted to be included in a final series.
> >
> > Signed-off-by: Edwin Török <edwin.torok@xxxxxxxxxx>
> > Signed-off-by: Frediano Ziglio <frediano.ziglio@xxxxxxxxxx>
>
> This patch is definitely out of order, seeing as you don't introduce the
> new hypercall until the following patch.
>

Yes and no. In the original PoC it was, as it was trying to check
performance difference using the new hypercall. But to prove that code
was working the new hypercalls were "emulated" using functions doing
map/copy/unmap. This also makes sure no performance regressions using
the new wrappers. So the code works with or without the new
hypercalls.

> But there's also absolutely no information what those stats are.  From
> memory, I think it was wallclock time of migrating a VM, but there are
> no units or sizes of the VM presented, so those are just random numbers.
>

I had the same though. I quickly searched if Edwin reappeared on ML
but it seems not at the moment.

> It also doesn't state whether it's measured from a PV or a PVH guest.
> However bad PV is (and it is bad), I think the improvement will be
> better in a PVH guest, because the foreign map/unmap operations being
> replaced are even more expensive in PVH.
>

The PoC was simply stripping out PV support so surely they were
PVH/HVM statistics.

> There's another area in libxenguest which would likely benefit; domain
> construction.  Even with kernels and initrds in the MB range, foreign
> copy is probalby a win, and it surely will be for e.g. the ACPI tables
> which are a few kB.
>
> ~Andrew

Frediano



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.