WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] why xen use x86_emulat ion() in page_fault

To: George Dunlap <George.Dunlap@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] why xen use x86_emulat ion() in page_fault
From: cc Luit <universalbillow@xxxxxxxxx>
Date: Tue, 11 Oct 2011 21:38:35 +0800
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Tue, 11 Oct 2011 06:39:33 -0700
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=2274LOttgpm+lfdr5/noGaVeF6oSUdCxRYR56OpmVM8=; b=Vwsw05G4WkvItHOgzpsVruXBT/izwpumjN6EBsyEMyk8mgpplMWsiZ8mWcfOONtdF0 V/LSQzmh/7fSMp1UwhIr1TBUycLcWtsn5flvDygxBQ29RtLxPJJwBy4gBXDjUevqzUx7 +JijT+s+r9d/zjvh80BxXaaHZe75GRZBaNy4c=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <CAFLBxZbZpZj+2am1uJ4UTy6GX4+hzAOAw5=12V2mF68g+=sf0g@xxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <CAFLBxZbLcqpcJfFRSnT_C=5krhen44EzMD5pKcDNGhvLYmck=g@xxxxxxxxxxxxxx> <CADWh-PF1BOSN22-Ua41fuRDP9HsHJ3j=T9j7_Kc2Un8XnVMKOQ@xxxxxxxxxxxxxx> <CAFLBxZZ4vqiQjGONJHKmRZqES5SJv71A9_kUkux6qjvo3407Ng@xxxxxxxxxxxxxx> <CADWh-PE=dPG4BJNUJkdr40f0d57brJvu+8wq6aEsd++mK6kAZQ@xxxxxxxxxxxxxx> <CAFLBxZbZpZj+2am1uJ4UTy6GX4+hzAOAw5=12V2mF68g+=sf0g@xxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx


On Tue, Oct 11, 2011 at 9:20 PM, George Dunlap <George.Dunlap@xxxxxxxxxxxxx> wrote:
On Tue, Oct 11, 2011 at 1:57 PM, cc Luit <universalbillow@xxxxxxxxx> wrote:
> appreciate your explanation so much, that's really detail and helpfull!
> but I think for the propagate from GPT to SPT, it's not always need the sync
> all the time, I know in the early version of xen there is not need to do
> that, but just the Lazy mode, which means (just what I understand, but not
> sure):
>  when guest os modify the GPT, do not emulate (there is no write-protected
> PTE, so guest can directly modify it)
>  1) when the access right ascension, the guest OS will INVLPG to shootdown
> TLB, so hypervisor can catch the INPLPG inst to sync  up the SPT/GPT
>  2) when access right down, when guest OS access this page it will trap to
> xen, xen will catch #PF to sync up SPT/GPT,

> We already do something like this for L1 pages; search for "SHOPT_OUT_OF_SYNC".

> But when you start to do this for higher-level pages (L2 and above),
> then you get into a lot of very tricky corner-cases.  Because changes
> to higher-level PTs are less common, we went with the simpler route of
> simply emulating all accesses to them.

> It could be done -- IIRC, version 1 of the shadow code did this
> (because there was very limited hypervisor emulation).  But to get it
> correct *and* working quickly will be kind of difficult.
 
Yeah, I see~

>> > bu ke qi! ;-)
>
> feel kind and amazed to see the Chinese Pinyin, really feel kind of you:-)

我学了中文学了两年。我常常要用那个! :-)
haha~你竟然会用到中文,第一次在Xen-devel上看到中文好兴奋啊。。。

 -George



--
- Luit @ Parallel Processing Institute, Fudan University 
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel