From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: Use host CPUID processor info Date: Sun, 08 Jul 2007 18:12:12 +0300 Message-ID: <4690FECC.5070307@qumranet.com> References: <10EA09EFD8728347A513008B6B0DA77A01B8F4B3@pdsmsx411.ccr.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org To: "Dong, Eddie" Return-path: In-Reply-To: <10EA09EFD8728347A513008B6B0DA77A01B8F4B3-wq7ZOvIWXbNpB2pF5aRoyrfspsVTdybXVpNB7YpNyf8@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org Dong, Eddie wrote: > Avi Kivity wrote: > >> One of the uses of virtualization is to abstract the underlying >> hardware, so that a VM image can run on any platform (live >> migration is >> an example of this use case). For that we must not let any detail of >> the hardware be visible. >> > > I doutb about the live migration cross different architecture. A VM > using AMD 3DNow can't be migrated to Intel Box. Even within Intel > processores, A VM using SSE2 can't be migrated to a platform w/o SSE2 > support. > > Only if the VM is using the minimal instruction set, minimal features > may be able to live migrate to other platforms. If this is the purpose, > probably we can use an ancient processor model for the VM to achieve > best migration capability in case hybrid processor is adopted. In that > way we meet both requirement: live migration and app doesn't know it is > a VM. > It doesn't have to be too ancient. All virtualization capable processors support at least sse2 (and maybe sse3 too). > Further more, there needs a capibility check for live migration to see > if it can be migrated to a new platform. If we use host processor model, > Qemu can simply check both new processor model and required one to see > if migration can be done, if we use virtual processor model, say qemu > processor, we have trouble: A vm using qemu processor compiled with SSE2 > can't be migrated to a new platform w/o SSE2 though the capability check > at migration decision make time says OK (both are qemu processoe). No, you only need to check that the host processor is a superset of the virtualized processor. A management solution can also compute a cpuid that is common to all machines in the farm and tell qemu to use that via the command line. -- error compiling committee.c: too many arguments to function ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/