[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] xenpaging:add a new array to speed up page-in in xenpaging



hongkaixing@xxxxxxxxxx writes ("[Xen-devel] [PATCH] xenpaging:add a new array 
to speed up page-in in xenpaging"):
> xenpaging:add a new array to speed up page-in in xenpaging
> 
> This patch adds a new array named page_out_index to reserve the
> victim's index.  When page in a page,it has to go through a for loop
> from 0 to num_pages to find the right page to read,and it costs much
> time in this loop.After adding the page_out_index array,it just
> reads the arrry to get the right page,and saves much time.

Thanks for this submission.  Olaf may well have some comments, but I
have some too:

> @@ -660,6 +672,7 @@
>              break;
>          if ( i % 100 == 0 )
>              DPRINTF("%d pages evicted\n", i);
> +        page_out_index[victims[i].gfn].index=i;

Surely this should be better done much closer to the actual point
where we page out ?

And you should reset the index entry when the page is read back in, I
think ?

Ian.

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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.