From mboxrd@z Thu Jan 1 00:00:00 1970 From: "H. Peter Anvin" Subject: Re: [PATCH -v2] kvm: Emulate MOVBE Date: Tue, 23 Apr 2013 16:50:43 -0700 Message-ID: <51771E53.30800@zytor.com> References: <20130414074107.GD17919@redhat.com> <20130414173215.GD20547@pd.tnic> <20130416174236.GE5807@redhat.com> <20130417110433.GD11807@pd.tnic> <20130417133829.GH1682@redhat.com> <20130417140200.GE11807@pd.tnic> <20130418224848.GA20712@pd.tnic> <20130421094651.GA8997@redhat.com> <20130421113051.GB4594@pd.tnic> <20130421125115.GD8997@redhat.com> <20130423234150.GA31444@pd.tnic> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: Gleb Natapov , Andre Przywara , kvm@vger.kernel.org, =?UTF-8?B?SsO2cmcgUsO2ZGVs?= , x86-ml To: Borislav Petkov Return-path: Received: from terminus.zytor.com ([198.137.202.10]:35396 "EHLO mail.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756596Ab3DWXvK (ORCPT ); Tue, 23 Apr 2013 19:51:10 -0400 In-Reply-To: <20130423234150.GA31444@pd.tnic> Sender: kvm-owner@vger.kernel.org List-ID: On 04/23/2013 04:41 PM, Borislav Petkov wrote: > > Btw, in thinking about this more, I'm kinda sceptical we want to use the > CPUID layout for this new KVM_GET_EMULATED_* ioctl. And the reason why > I'm sceptical is that not every instruction is behind a CPUID capability > bit and if we want to tell userspace that we do emulate any insn, even > one for which there's no CPUID bit, we're going to have to either > simulate a kvm-specific CPUID leaf or, maybe even better, come up with > our own format for emulated capabilities. Maybe a bit vector with set > bits for the respective capability, or something more nifty. > > In any case, it doesn't really need to be CPUID-like, IMHO. > Using CPUID has the major advantage that it is well-defined. -hpa