On Tue, Mar 05, 2024 at 03:43:41PM +0100, Markus Armbruster wrote:
Peter Maydell <peter.maydell@linaro.org> writes:
On Mon, 4 Mar 2024 at 13:52, Maksim Davydov <davydov-max@yandex-team.ru> wrote:
The following changes since commit e1007b6bab5cf97705bf4f2aaec1f607787355b8:
Merge tag 'pull-request-2024-03-01' of https://gitlab.com/thuth/qemu into staging (2024-03-01 10:14:32 +0000)
are available in the Git repository at:
https://gitlab.com/davydov-max/qemu.git tags/pull-compare-mt-2024-03-04
for you to fetch changes up to 7693a2e8518811a907d73a85807ee71dac8fabcb:
scripts: add script to compare compatibility properties (2024-03-04 14:10:53 +0300)
----------------------------------------------------------------
Please note. This is the first pull request from me.
My public GPG key is available here
https://keys.openpgp.org/vks/v1/by-fingerprint/CDB5BEEF8837142579F5CDFE8E927E10F72F78D4
----------------------------------------------------------------
scripts: add a new script for machine development
----------------------------------------------------------------
Hi; I would prefer this to go through some existing submaintainer
tree if possible, please.
Migration? QOM? Not sure. Cc'ing the maintainers anyway.
Yeah this seems like migration relevant.. however now I'm slightly confused
on when this script should be useful.
According to:
https://lore.kernel.org/qemu-devel/20240222153912.646053-5-davydov-max@yandex-team.ru/
This script runs QEMU to obtain compat_props of machines and
default values of different types of drivers to produce comparison
table. This table can be used to compare machine types to choose
the most suitable machine or compare binaries to be sure that
migration to the newer version will save all device
properties. Also the json or csv format of this table can be used
to check does a new machine affect the previous ones by comparing
tables with and without the new machine.
In regards to "choose the most suitable machine": why do you need to choose
a machine?
If it's pretty standalone setup, shouldn't we always try to use the latest
machine type if possible (as normally compat props are only used to keep
compatible with old machine types, and the default should always be
preferred). If it's a cluster setup, IMHO it should depend on the oldest
QEMU version that plans to be supported. I don't see how such comparison
helps yet in either of the cases..
In regards to "compare binaries to be sure that migration to the newer
version will save all device properties": do we even support migrating
_between_ machine types??
Sololy relying on compat properties to detect device compatibility is also
not reliable. For example, see VMStateField.field_exists() or similarly,
VMStateDescription.needed(), which are hooks that device can provide to
dynamically decide what device state to be saved/loaded. Such things are
not reflected in compat properties, so even if compat properties of all
devices are the same between two machine types, it may not mean that the
migration stream will always be compatible.
Thanks,