summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_synch.c
diff options
context:
space:
mode:
authordillon <dillon@FreeBSD.org>2002-07-12 20:17:06 +0000
committerdillon <dillon@FreeBSD.org>2002-07-12 20:17:06 +0000
commitdc5d856e710c7a79039e46c89de1624670a57c92 (patch)
treeb4ac30b07b35f56e5b15e9d9fed028a0cb87849e /sys/kern/kern_synch.c
parentc5495020cb1a3babc0521d7c9de49291cd5fb515 (diff)
downloadFreeBSD-src-dc5d856e710c7a79039e46c89de1624670a57c92.zip
FreeBSD-src-dc5d856e710c7a79039e46c89de1624670a57c92.tar.gz
Re-enable the idle page-zeroing code. Remove all IPIs from the idle
page-zeroing code as well as from the general page-zeroing code and use a lazy tlb page invalidation scheme based on a callback made at the end of mi_switch. A number of people came up with this idea at the same time so credit belongs to Peter, John, and Jake as well. Two-way SMP buildworld -j 5 tests (second run, after stabilization) 2282.76 real 2515.17 user 704.22 sys before peter's IPI commit 2266.69 real 2467.50 user 633.77 sys after peter's commit 2232.80 real 2468.99 user 615.89 sys after this commit Reviewed by: peter, jhb Approved by: peter
Diffstat (limited to 'sys/kern/kern_synch.c')
-rw-r--r--sys/kern/kern_synch.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/kern/kern_synch.c b/sys/kern/kern_synch.c
index 765f4b0..53ab46f 100644
--- a/sys/kern/kern_synch.c
+++ b/sys/kern/kern_synch.c
@@ -892,6 +892,13 @@ mi_switch()
if (PCPU_GET(switchtime.sec) == 0)
binuptime(PCPU_PTR(switchtime));
PCPU_SET(switchticks, ticks);
+
+ /*
+ * Call the switchin function while still holding the scheduler lock
+ * (used by the idlezero code and the general page-zeroing code)
+ */
+ if (td->td_switchin)
+ td->td_switchin();
}
/*
OpenPOWER on IntegriCloud