From mboxrd@z Thu Jan 1 00:00:00 1970 From: Borislav Petkov Subject: Re: [RFC PATCH] Emulate MOVBE Date: Wed, 10 Apr 2013 11:53:33 +0200 Message-ID: <20130410095333.GB13394@pd.tnic> References: <20130409234602.GI5077@pd.tnic> <20130410000326.GA3768@nazgul.tnic> <5164AC76.7070704@zytor.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Cc: kvm@vger.kernel.org, Andre Przywara , =?utf-8?B?SsO2cmcgUsO2ZGVs?= , x86-ml To: "H. Peter Anvin" Return-path: Received: from mail.skyhub.de ([78.46.96.112]:39849 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751347Ab3DJJxg (ORCPT ); Wed, 10 Apr 2013 05:53:36 -0400 Content-Disposition: inline In-Reply-To: <5164AC76.7070704@zytor.com> Sender: kvm-owner@vger.kernel.org List-ID: On Tue, Apr 09, 2013 at 05:04:06PM -0700, H. Peter Anvin wrote: > On 04/09/2013 05:03 PM, Borislav Petkov wrote: > > > > Note to self: this destroys the src operand but it shouldn't. Fix it > > tomorrow. > > > > I thought movbe was already in qemu just not on by default...? Yep, this went upstream just last month. However and AFAICT, this still doesn't help the issue when we run qemu -enable-kvm and the host doesn't have MOVBE. With my simplistic thinking, I would expect that kvm would jump to qemu on #UD and let it emulate the unsupported instruction and go back. However, as Andre explained it to me, qemu emulation and kvm are completely unrelated and it is probably very expensive to copy emulation states to and fro just for a simple instruction. Thus, this simpler approach to do the emulation straight in kvm as it is done already for a bunch of other instructions. -- Regards/Gruss, Boris. Sent from a fat crate under my desk. Formatting is fine. --