summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_clock.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2006-02-08 08:09:17 +0000
committerphk <phk@FreeBSD.org>2006-02-08 08:09:17 +0000
commit74f8e63a104485f17205e2a3e446e00f968c324c (patch)
treedcc7f358367ea74ccf47cede57e272875e9b589d /sys/kern/kern_clock.c
parent4d8070a25b5c7585b416e8a3db16fc15f2e3cd13 (diff)
downloadFreeBSD-src-74f8e63a104485f17205e2a3e446e00f968c324c.zip
FreeBSD-src-74f8e63a104485f17205e2a3e446e00f968c324c.tar.gz
Simplify system time accounting for profiling.
Rename struct thread's td_sticks to td_pticks, we will need the other name for more appropriately named use shortly. Reduce it from uint64_t to u_int. Clear td_pticks whenever we enter the kernel instead of recording its value as reference for userret(). Use the absolute value of td->pticks in userret() and eliminate third argument.
Diffstat (limited to 'sys/kern/kern_clock.c')
-rw-r--r--sys/kern/kern_clock.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/kern_clock.c b/sys/kern/kern_clock.c
index 33336b9..0316c3e 100644
--- a/sys/kern/kern_clock.c
+++ b/sys/kern/kern_clock.c
@@ -440,7 +440,7 @@ statclock(int usermode)
} else {
if (p->p_flag & P_SA)
thread_statclock(0);
- td->td_sticks++;
+ td->td_pticks++;
p->p_rux.rux_sticks++;
if (td != PCPU_GET(idlethread))
cp_time[CP_SYS]++;
OpenPOWER on IntegriCloud