> Hi. 
> 
> Isn't the page coloring algoritm in _vm_page_list_find totally bogus?
> 

No, it's not.  The comment is, however, misplaced.  It describes
the behavior of an inline function in vm_page.h, and not the function
it precedes.

> It skips queue pq[index & PQ_L2_MASK].
> 

That's correct.  The inline function vm_page_list_find() in vm_page.h
has already failed to allocate a page of the desired color, index,
and so _vm_page_list_find() is called to allocate a page of ANY other
color it can find.

Rather than choose a random page, the odd-looking loop in
_vm_page_list_find() tries to find a page whose color is unlikely
to equal the neighboring pages in the vm object if colored allocation
for them succeeded.

Alan


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to