From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Otte Subject: Re: swapping with MMU Notifiers V2 Date: Wed, 30 Jan 2008 12:26:39 +0100 Message-ID: <47A05EEF.3010701@de.ibm.com> References: <20080129145021.GJ7233@v2.random> <479F50D6.4020005@de.ibm.com> <479F532C.1020503@qumranet.com> <479F55D6.1090807@de.ibm.com> <20080129175420.GR7233@v2.random> Reply-To: carsteno-tA70FqPdS9bQT0dZR+AlfA@public.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: carsteno-tA70FqPdS9bQT0dZR+AlfA@public.gmane.org, kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org, Avi Kivity To: Andrea Arcangeli Return-path: In-Reply-To: <20080129175420.GR7233-lysg2Xt5kKMAvxtiuMwx3w@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org Andrea Arcangeli wrote: > By your conclusion I suppose you thought NPT maps guest physical to > host virtual. If it was the case the cpu would to walk three layer of > pagetables (each layer is an arrow): guest virtual -> guest physical > -> host virtual -> host physical. Instead it's just guest virtual -> > guest physical -> host physical. Or even less for shadow: guest > virtual -> host physical, which is why shadow should be faster for > number crunching still (and definitely slower for dbms). No, I was assuming guest virtual -> guest physical -> host physical. We do the same. We just re-use the very same page table that maps gp to hp to map host userland to hp. The only tricky part for AMD64 is to hide host userland parts from the guest that are not supposed to be visible to the guest-os as far as I see. ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/