svn commit: r247549 - projects/calloutng/sys/kern
Alexander Motin
mav at FreeBSD.org
Fri Mar 1 15:09:24 UTC 2013
Author: mav
Date: Fri Mar 1 15:09:23 2013
New Revision: 247549
URL: http://svnweb.freebsd.org/changeset/base/247549
Log:
Change CC_HASH_SHIFT from 10 to 8, changing callwheel bucket size from 1ms
to 4ms. This allows to reduce time consumed by callout_process() on linear
travense through the array of empty buckets on systems with few callouts.
On systems with many callouts result depends on callouts time and precision:
smaller CC_HASH_SHIFT value improves handling of long callouts, while bigger
value improves handling of short and precise (not aggregable) ones.
Modified:
projects/calloutng/sys/kern/kern_timeout.c
Modified: projects/calloutng/sys/kern/kern_timeout.c
==============================================================================
--- projects/calloutng/sys/kern/kern_timeout.c Fri Mar 1 14:54:37 2013 (r247548)
+++ projects/calloutng/sys/kern/kern_timeout.c Fri Mar 1 15:09:23 2013 (r247549)
@@ -367,7 +367,7 @@ start_softclock(void *dummy)
SYSINIT(start_softclock, SI_SUB_SOFTINTR, SI_ORDER_FIRST, start_softclock, NULL);
-#define CC_HASH_SHIFT 10
+#define CC_HASH_SHIFT 8
static inline u_int
callout_hash(sbintime_t sbt)
More information about the svn-src-projects
mailing list