I've seen the following panic quite frequently whilst running the stress tests. I've also seen this occurring during large builds:
panic ../vm/vm_page.c:1618: vm_page_alloc_pa: vm_page: privileged thread unable to allocate page I found that there were occasionally high numbers of pages being allocated to non-vm-privileged threads at times when normal page allocation is suspended. Those pages were allocated from the cpu pool cache which didn't consider vm_page_alloc_paused. Page allocation normally ceases once the pool is emptied unless pageout had released sufficient pages. In very particular cases, the result can be more serious if the pool is replenished by a privileged thread before the non-vm-privileged thread is forced into page wait. In this case the pool can be emptied an additional time. Catstrophe occasionally results in this sequence repeating often enough for every single page to be allocated. I've run the stress tests for several hours without this recurring. I have some local debug logging that shows the minimum known free page count since boot. With this patch, the low point remains ~150M of memory whereas without this patch it would quickly drop to ~20M and occasionally 0M with the panic. Cheers, Mike.
