From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Michael S. Tsirkin" Subject: Re: [RFC PATCH 0/2] Expose available KVM free memory slot count to help avoid aborts Date: Thu, 27 Jan 2011 11:28:47 +0200 Message-ID: <20110127092847.GB30424@redhat.com> References: <4D3F0974.3040904@redhat.com> <20110125175839.GC17734@redhat.com> <4D3FE697.4010502@redhat.com> <20110126092038.GD2704@redhat.com> <4D3FE809.6020102@redhat.com> <20110126093933.GF2704@redhat.com> <4D3FEF4D.9080008@redhat.com> <20110126120851.GA11913@redhat.com> <4D41392B.2070609@redhat.com> <20110127092619.GA30424@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Alex Williamson , Jan Kiszka , Marcelo Tosatti , "kvm@vger.kernel.org" , "ddutile@redhat.com" , "chrisw@redhat.com" To: Avi Kivity Return-path: Received: from mx1.redhat.com ([209.132.183.28]:6637 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753522Ab1A0J3F (ORCPT ); Thu, 27 Jan 2011 04:29:05 -0500 Content-Disposition: inline In-Reply-To: <20110127092619.GA30424@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On Thu, Jan 27, 2011 at 11:26:19AM +0200, Michael S. Tsirkin wrote: > On Thu, Jan 27, 2011 at 11:21:47AM +0200, Avi Kivity wrote: > > On 01/26/2011 02:08 PM, Michael S. Tsirkin wrote: > > >> > > > >> >I just mean that once you fault you map sptes and then you can use them > > >> >without exits. mmio will cause exits each time. Right? > > >> > > >> The swapper scanning sptes, ksmd, khugepaged, and swapping can all > > >> cause a page to be unmapped. Though it should certainly happen with > > >> a much lower frequency than mmio. > > > > > >Right. That's why I say that sorting by size might not be optimal. > > >Maybe a cache ... > > > > Why would it not be optimal? > > > > If you have 16GB RAM in two slots and a few megabytes here and there > > scattered in some slots, you have three orders of magnitudes to > > spare. > > Yes but you might not be accessing all that RAM. > Maybe your workset is just tens of megabytes. Anyway, what I am saying this is all just guesswork. Some kind of cache sounds, to me, like a better approach if we have a ton of slots. > > -- > > error compiling committee.c: too many arguments to function