svn commit: r215598 - in stable/8/sys: sparc64/include vm

Marius Strobl marius at FreeBSD.org
Sun Nov 21 00:45:19 UTC 2010


Author: marius
Date: Sun Nov 21 00:45:18 2010
New Revision: 215598
URL: http://svn.freebsd.org/changeset/base/215598

Log:
  MFC: r215093
  
  Enable reservation-based physical memory allocation.  Even without the
  creation of large page mappings in the pmap, it can provide modest
  performance benefits.  In particular, for a "buildworld" on a 2x 1GHz
  Ultrasparc IIIi it reduced the wall clock time by 2.2% and the system
  time by 12.6%.
  
  Tested by:	marius@

Modified:
  stable/8/sys/sparc64/include/vmparam.h
  stable/8/sys/vm/vm_reserv.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/xen/xenpci/   (props changed)

Modified: stable/8/sys/sparc64/include/vmparam.h
==============================================================================
--- stable/8/sys/sparc64/include/vmparam.h	Sat Nov 20 22:30:09 2010	(r215597)
+++ stable/8/sys/sparc64/include/vmparam.h	Sun Nov 21 00:45:18 2010	(r215598)
@@ -121,10 +121,17 @@
 #define	VM_NFREEORDER		12
 
 /*
- * Disable superpage reservations.
+ * Enable superpage reservations: 1 level.
  */
 #ifndef	VM_NRESERVLEVEL
-#define	VM_NRESERVLEVEL		0
+#define	VM_NRESERVLEVEL		1
+#endif
+
+/*
+ * Level 0 reservations consist of 512 pages.
+ */
+#ifndef	VM_LEVEL_0_ORDER
+#define	VM_LEVEL_0_ORDER	9
 #endif
 
 /*

Modified: stable/8/sys/vm/vm_reserv.c
==============================================================================
--- stable/8/sys/vm/vm_reserv.c	Sat Nov 20 22:30:09 2010	(r215597)
+++ stable/8/sys/vm/vm_reserv.c	Sun Nov 21 00:45:18 2010	(r215598)
@@ -197,7 +197,7 @@ sysctl_vm_reserv_partpopq(SYSCTL_HANDLER
 		}
 		mtx_unlock(&vm_page_queue_free_mtx);
 		sbuf_printf(&sbuf, "%5d: %6dK, %6d\n", level,
-		    unused_pages * (PAGE_SIZE / 1024), counter);
+		    unused_pages * ((int)PAGE_SIZE / 1024), counter);
 	}
 	sbuf_finish(&sbuf);
 	error = SYSCTL_OUT(req, sbuf_data(&sbuf), sbuf_len(&sbuf));


More information about the svn-src-all mailing list