svn commit: r235854 - head/sys/vm

Maksim Yevmenkin emax at FreeBSD.org
Wed May 23 18:56:30 UTC 2012


Author: emax
Date: Wed May 23 18:56:29 2012
New Revision: 235854
URL: http://svn.freebsd.org/changeset/base/235854

Log:
  Tweak condition for disabling allocation from per-CPU buckets in
  low memory situation. I've observed a situation where per-CPU
  allocations were disabled while there were enough free cached pages.
  Basically, cnt.v_free_count was sitting stable at a value lower
  than cnt.v_free_min and that caused massive performance drop.
  
  Reviewed by:	alc
  MFC after:	1 week

Modified:
  head/sys/vm/uma_core.c

Modified: head/sys/vm/uma_core.c
==============================================================================
--- head/sys/vm/uma_core.c	Wed May 23 18:41:45 2012	(r235853)
+++ head/sys/vm/uma_core.c	Wed May 23 18:56:29 2012	(r235854)
@@ -272,10 +272,7 @@ SYSCTL_PROC(_vm, OID_AUTO, zone_stats, C
 static void
 bucket_enable(void)
 {
-	if (cnt.v_free_count < cnt.v_free_min)
-		bucketdisable = 1;
-	else
-		bucketdisable = 0;
+	bucketdisable = vm_page_count_min();
 }
 
 /*


More information about the svn-src-all mailing list