Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 26 Apr 2000 04:42:21 +1000 (EST)
From:      Bruce Evans <bde@zeta.org.au>
To:        Kees Hendrikse <kees@echelon.nl>
Cc:        freebsd-bugs@FreeBSD.ORG
Subject:   Re: kern/17842: Erratic user time reports for long running processes
Message-ID:  <Pine.BSF.4.21.0004260421140.5989-100000@alphplex.bde.org>
In-Reply-To: <200004250840.BAA70268@freefall.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
>  What baffles me most: why stop counting at 379265,687860 seconds? 

The multiplication in "uu = (tu * ut) / tt;" in kern_resource.c
overflows near there.  Here tu is the total time in usec, ut is the
user tick count and tt is the total tick count.  If all ticks are user
ticks, then overflow occurs for tu = sqrt(2^64 / 10^6 / hz) = 429496
seconds when hz = 100.  Normally there are some interrupt and system
ticks, so overflow occurs for a somewhat larger tu and a somewhat
smaller ut -- apparently about 379 / 429 times smaller in your case.

4.0 enforces monotonicity of the resource times, so truncated values
resulting from the overflow don't cause the resource times to stick
at the first value where overflow occurs.

Bruce



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0004260421140.5989-100000>