[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20200515135845.GA17572@linux.intel.com>
Date: Fri, 15 May 2020 06:58:45 -0700
From: Sean Christopherson <sean.j.christopherson@...el.com>
To: Vitaly Kuznetsov <vkuznets@...hat.com>
Cc: kvm@...r.kernel.org, linux-kernel@...r.kernel.org,
Michael Tsirkin <mst@...hat.com>,
Julia Suvorova <jsuvorov@...hat.com>,
Paolo Bonzini <pbonzini@...hat.com>,
Wanpeng Li <wanpengli@...cent.com>,
Jim Mattson <jmattson@...gle.com>, x86@...nel.org
Subject: Re: [PATCH RFC 4/5] KVM: x86: aggressively map PTEs in
KVM_MEM_ALLONES slots
On Fri, May 15, 2020 at 10:36:19AM +0200, Vitaly Kuznetsov wrote:
> Sean Christopherson <sean.j.christopherson@...el.com> writes:
> > IMO this is a waste of memory and TLB entries. Why not treat the access as
> > the MMIO it is and emulate the access with a 0xff return value? I think
> > it'd be a simple change to have __kvm_read_guest_page() stuff 0xff, i.e. a
> > kvm_allones_pg wouldn't be needed. I would even vote to never create an
> > MMIO SPTE. The guest has bigger issues if reading from a PCI hole is
> > performance sensitive.
>
> You're trying to defeat the sole purpose of the feature :-) I also saw
> the option you suggest but Michael convinced me we should go further.
>
> The idea (besides memory waste) was that the time we spend on PCI scan
> during boot is significant.
Put that in the cover letter. The impression I got from the current cover
letter is that the focus was entirely on memory consumption.
> Unfortunatelly, I don't have any numbers but we can certainly try to get
> them.
Numbers are definitely required, otherwise we'll have no idea whether doing
something like the agressive prefetch actually has a meaningful impact.
> With this feature (AFAIU) we're not aiming at 'classic' long-living VMs but
> rather at something like Kata containers/FaaS/... where boot time is crucial.
Isn't the guest kernel fully controlled by the VMM in those use cases?
Why not enlighten the guest kernel in some way so that it doesn't have to
spend time scanning PCI space in the first place?
Powered by blists - more mailing lists