aboutsummaryrefslogtreecommitdiff
path: root/sys/kern
diff options
context:
space:
mode:
authorBruce Evans <bde@FreeBSD.org>1996-10-25 13:01:56 +0000
committerBruce Evans <bde@FreeBSD.org>1996-10-25 13:01:56 +0000
commit835bd1ce62ebd0b706c83528cc57a9f4a005d617 (patch)
tree5968eb78feb617d966921606e10992b228f61554 /sys/kern
parent22b9cd6f99c5bdb80b197cf30657b937861a39b0 (diff)
downloadsrc-835bd1ce62ebd0b706c83528cc57a9f4a005d617.tar.gz
src-835bd1ce62ebd0b706c83528cc57a9f4a005d617.zip
Improved biasing of i586 clock by adjusting for hardclock() latency.
I decided to do this for every hardclock() call instead of lazily in microtime(). The lazy method is simpler but has more overhead if microtime() is called a lot. CPU_THISTICKLEN() is now a no-op and should probably go away. Previously it did nothing directly but had the side effect of setting i586_last_tick for CPU_CLOCKUPDATE() and i586_avg_tick for debugging. CPU_CLOCKUPDATE() now uses a better method and i586_avg_tick is too much trouble to maintain. Reduced nesting of #includes in the usual case. Increased nesting of #includes when CLOCK_HAIR is defined. This is a kludge to get typedefs for inline functions only when the inline functions are used. Normally only kern_clock.c defines this. kern_clock.c can't include the i386 headers directly. Removed unused LOCORE support.
Notes
Notes: svn path=/head/; revision=19172
Diffstat (limited to 'sys/kern')
-rw-r--r--sys/kern/kern_clock.c3
-rw-r--r--sys/kern/kern_tc.c3
-rw-r--r--sys/kern/kern_timeout.c3
3 files changed, 6 insertions, 3 deletions
diff --git a/sys/kern/kern_clock.c b/sys/kern/kern_clock.c
index d94d53ea6237..b1f3bb061552 100644
--- a/sys/kern/kern_clock.c
+++ b/sys/kern/kern_clock.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_clock.c 8.5 (Berkeley) 1/21/94
- * $Id: kern_clock.c,v 1.26 1996/07/30 16:59:22 bde Exp $
+ * $Id: kern_clock.c,v 1.27 1996/10/10 10:25:03 bde Exp $
*/
/* Portions of this software are covered by the following: */
@@ -76,6 +76,7 @@
#include <sys/sysctl.h>
#include <machine/cpu.h>
+#define CLOCK_HAIR /* XXX */
#include <machine/clock.h>
#ifdef GPROF
diff --git a/sys/kern/kern_tc.c b/sys/kern/kern_tc.c
index d94d53ea6237..b1f3bb061552 100644
--- a/sys/kern/kern_tc.c
+++ b/sys/kern/kern_tc.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_clock.c 8.5 (Berkeley) 1/21/94
- * $Id: kern_clock.c,v 1.26 1996/07/30 16:59:22 bde Exp $
+ * $Id: kern_clock.c,v 1.27 1996/10/10 10:25:03 bde Exp $
*/
/* Portions of this software are covered by the following: */
@@ -76,6 +76,7 @@
#include <sys/sysctl.h>
#include <machine/cpu.h>
+#define CLOCK_HAIR /* XXX */
#include <machine/clock.h>
#ifdef GPROF
diff --git a/sys/kern/kern_timeout.c b/sys/kern/kern_timeout.c
index d94d53ea6237..b1f3bb061552 100644
--- a/sys/kern/kern_timeout.c
+++ b/sys/kern/kern_timeout.c
@@ -36,7 +36,7 @@
* SUCH DAMAGE.
*
* @(#)kern_clock.c 8.5 (Berkeley) 1/21/94
- * $Id: kern_clock.c,v 1.26 1996/07/30 16:59:22 bde Exp $
+ * $Id: kern_clock.c,v 1.27 1996/10/10 10:25:03 bde Exp $
*/
/* Portions of this software are covered by the following: */
@@ -76,6 +76,7 @@
#include <sys/sysctl.h>
#include <machine/cpu.h>
+#define CLOCK_HAIR /* XXX */
#include <machine/clock.h>
#ifdef GPROF