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

[Xen-devel][PATCH]Provide 3 times continously writes check and unshadow

To: <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel][PATCH]Provide 3 times continously writes check and unshadow the guest page
From: "Xin, Xiaohui" <xiaohui.xin@xxxxxxxxx>
Date: Wed, 23 Jan 2008 13:41:32 +0800
Delivery-date: Tue, 22 Jan 2008 21:42:08 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
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/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: Achdgpvka8w6to1sSySn8I1yi6Lqng==
Thread-topic: [Xen-devel][PATCH]Provide 3 times continously writes check and unshadow the guest page

The patch checks if the guest continuously writes 3 times to the same guest page table pages, if yes, then unshadow the guest pages. The idea is copied from the KVM side. And since the idea has overlapped with the now optimization in the now Xen shadow code, so the patch removes the optimization part which when the guest writes 2 continuously 0 to the same page, then unshadow the guest page.

 

In the latest Xen, if we use iperf to test the NIC assigned to HVM guest, we will find that the performance data is very unstable and low especially with an ia32pae guest. The root cause is that Xen holds the guest page table pages even when they changes to data pages, and at that time if guest write pure data to the paged, Xen will get many unnecessary pages faults. It hurts the iperf performance a lot. The patch resolves the issue (compare to the old optimization). And considering the side effects to the other benchmark, we have a test result as followed.

 

Benchmark

Guest OS

with out the patch

with the patch

Gain(+)/Downgrade(-)

 

 

 

 

 

Sysbench

Windows XP (32pae)

58.4704

58.8196

-0.59%

 

Windows XP (ia32e)

31.2266

31.6322

-1.30%

Specjbb

Linux (32pae)

1530.52

1525.27

-0.34%

 

Linux (ia32e

975.94

970.44

-0.56%

Kernel Build

Linux (32pae)

1m44s

1m43s

+0.96%

 

Linux (ia32e)

2m38s

2m23s

+9.5%

Sysmark2007

 

 

 

 

   E-learning

Windows XP (32pae)

55

56

+1.8%

   Video Creation

Windows XP (32pae)

49

48

-2%

   Productivity (cannot run)

 

 

 

 

   3D (cannot run)

 

 

 

 

Iperf

Linux (32pae)

Very unstable from ~50M/bs to 500M/bs

Stable ~550M/bs

 

 

 

Signed-off-by Xin Xiaohui xiaohui.xin@xxxxxxxxx

Signed-off-by Dong Eddie <eddie.dong@xxxxxxxxx>

 

 

 

 

 

 

 

Attachment: 3-writes-unshadow.diff
Description: 3-writes-unshadow.diff

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel