[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] CPUID feature bits not saved with migration
From: |
Andre Przywara |
Subject: |
Re: [Qemu-devel] CPUID feature bits not saved with migration |
Date: |
Thu, 16 Jul 2009 12:08:22 +0200 |
User-agent: |
Thunderbird 2.0.0.14 (X11/20080508) |
Jamie Lokier wrote:
Anthony Liguori wrote:
It's unclear what to do about -cpu host. If we did migrate cpuid
values, then -cpu would effectively be ignored after an incoming migration.
The new host might not support all the cpuid features of the old host,
whether by -cpu host or explicit cpuid. What happens then?
If you plan to migrate, you should think of this in advance. I have a
rough version of a tool to compute the least common denominator CPUID
bits given either processor (code)names or host names. In the latter
case it will login into the box and query the host's CPUID. The tool
then generates a QEMU command line (like -cpu qemu64,-mwait,-popcnt)
with which the guest should be started.
This should ensure that the guest always sees the same subset of the
CPUs capabilities.
For changing cpuid when migrating, as you might like to do with -cpu
host for performance, is reboot-during-migrate useful? It would make
sure all disk state is committed to the image files asynchronously
while the machine continues to run (just like normal migration), and
at the last moment transfers control and the machine sees a reboot,
permitting devices changes including cpuid change.
Is that really useful? After all the sexy part of live migration is the
"live" component...
CPU hotplug could be used for cpuid change in theory, but I doubt if
any guests or guest apps would handle it well.
Hotplugging could work for secondary processors, but hotplugging the BSP
is kind of tricky. And this does not solve the userspace issues, where
libraries detect CPU capabilities during startup and use optimized code
paths. AFAIK there is no mechanism of informing those libraries about a
CPUID change.
Regards,
Andre.
--
Andre Przywara
AMD-Operating System Research Center (OSRC), Dresden, Germany
Tel: +49 351 448 3567 12
----to satisfy European Law for business letters:
Advanced Micro Devices GmbH
Karl-Hammerschmidt-Str. 34, 85609 Dornach b. Muenchen
Geschaeftsfuehrer: Thomas M. McCoy; Giuliano Meroni
Sitz: Dornach, Gemeinde Aschheim, Landkreis Muenchen
Registergericht Muenchen, HRB Nr. 43632
Re: [Qemu-devel] CPUID feature bits not saved with migration, Andre Przywara, 2009/07/16