From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S967194AbdLSMmL (ORCPT ); Tue, 19 Dec 2017 07:42:11 -0500 Received: from mx1.redhat.com ([209.132.183.28]:33288 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S935074AbdLSMmH (ORCPT ); Tue, 19 Dec 2017 07:42:07 -0500 Subject: Re: [PATCH RFC 0/7] KVM: nVMX: enlightened VMCS initial implementation To: Vitaly Kuznetsov , kvm@vger.kernel.org Cc: x86@kernel.org, =?UTF-8?B?UmFkaW0gS3LEjW3DocWZ?= , "K. Y. Srinivasan" , Haiyang Zhang , Stephen Hemminger , "Michael Kelley (EOSG)" , Mohammed Gamal , Cathy Avery , Bandan Das , Roman Kagan , linux-kernel@vger.kernel.org, devel@linuxdriverproject.org References: <20171218171742.5765-1-vkuznets@redhat.com> From: Paolo Bonzini Message-ID: Date: Tue, 19 Dec 2017 13:41:58 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: <20171218171742.5765-1-vkuznets@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Tue, 19 Dec 2017 12:42:07 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 18/12/2017 18:17, Vitaly Kuznetsov wrote: > The original author of these patches does no longer work at Red Hat, I > agreed to take this over and send upstream. Here is his original > description: > > "Makes KVM implement the enlightened VMCS feature per Hyper-V TLFS 5.0b. > I've measured about %5 improvement in cost of a nested VM exit (Hyper-V > enabled Windows Server 2016 nested in KVM)." Can you try reproducing this and see how much a simple CPUID loop costs in: * Hyper-V on Hyper-V (with enlightened VMCS, as a proxy for a full implementation including the clean fields mask) * Hyper-V on KVM, with and without enlightened VMCS The latest kvm/queue branch already cut a lot of the cost of a nested VM exit (from ~22000 to ~14000 clock cycles for KVM on KVM), so we could also see if Hyper-V needs shadowing of more fields. > This is just an initial implementation. By leveraging clean fields mask > we can further improve performance. I'm also interested in implementing > the other part of the feature: consuming enlightened VMCS when KVM is > running on top of Hyper-V. I'm also interested in consuming enlightened VMCS on Hyper-V if that can provide better performance for KVM on Azure. Paolo