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

Re: [Xen-devel] [PATCH 06 of 10] xenpaging: improve performance in policy_choose_victim


  • To: xen-devel@xxxxxxxxxxxxxxxxxxx
  • From: Olaf Hering <olaf@xxxxxxxxx>
  • Date: Tue, 14 Feb 2012 22:08:51 +0100
  • Delivery-date: Tue, 14 Feb 2012 21:09:35 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>

On Mon, Jan 30, Olaf Hering wrote:

> +++ b/tools/xenpaging/policy_default.c
> @@ -80,33 +80,58 @@ int policy_init(struct xenpaging *paging
>  unsigned long policy_choose_victim(struct xenpaging *paging)

> +
> +        /* gfn busy */
> +        if ( test_bit(current_gfn, bitmap) )
> +            continue;
> +
> +        /* gfn already tested */
> +        if ( test_bit(current_gfn, bitmap) )
> +            continue;
> +
> +        /* gfn found */
> +        break;

The second one should be "unconsumed" instead of "bitmap", otherwise
wraparounds lead to endless loop in caller..

Olaf

_______________________________________________
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®.