From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: about vEOI optimization Date: Wed, 24 Aug 2011 13:00:11 +0300 Message-ID: <4E54CBAB.5070401@redhat.com> References: <625BA99ED14B2D499DC4E29D8138F150630051F1F5@shsmsx502.ccr.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: "kvm@vger.kernel.org" , "Nakajima, Jun" To: "Tian, Kevin" Return-path: Received: from mx1.redhat.com ([209.132.183.28]:16766 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750855Ab1HXKAR (ORCPT ); Wed, 24 Aug 2011 06:00:17 -0400 In-Reply-To: <625BA99ED14B2D499DC4E29D8138F150630051F1F5@shsmsx502.ccr.corp.intel.com> Sender: kvm-owner@vger.kernel.org List-ID: On 08/23/2011 11:09 AM, Tian, Kevin wrote: > Hi, Avi, > > Both Eddie and Marcello once suggested vEOI optimization by skipping > heavy-weight instruction decode, which reduces vEOI overhead greatly: > > http://www.mail-archive.com/kvm@vger.kernel.org/msg18619.html > http://www.spinics.net/lists/kvm/msg36691.html > > Though virtual x2apic serves similar purpose, it depends on guest OS > to support x2apic. Many Windows versions don't support x2apic though, > including Win7, Windows server before 2008 R2, etc. Given that virtualization > need support various OS versions, any chance to incorporate above vEOI > optimization in KVM as an alternative to boost performance when guest > doesn't support x2apic? > Yes. There was a problem with the guest using MOVSD or STOSD to write the EOI; if we don't emulate, then registers don't get updated. I guess we can ignore it since no sane guest will use those instructions for EOI. Another option is the hyper-V EOI support, which can also eliminate the EOI exit when no additional interrupt is pending. This can improve EOI performance even more. -- I have a truly marvellous patch that fixes the bug which this signature is too narrow to contain.