PERFORCE change 93252 for review
John Baldwin
jhb at FreeBSD.org
Mon Mar 13 16:15:44 UTC 2006
http://perforce.freebsd.org/chv.cgi?CH=93252
Change 93252 by jhb at jhb_slimer on 2006/03/13 16:14:33
Drop these local diffs now that phk has committed something
similar to HEAD.
Affected files ...
.. //depot/projects/smpng/sys/kern/kern_resource.c#60 edit
Differences ...
==== //depot/projects/smpng/sys/kern/kern_resource.c#60 (text+ko) ====
@@ -761,19 +761,14 @@
ut = ruxp->rux_uticks;
st = ruxp->rux_sticks;
it = ruxp->rux_iticks;
+ tu = ruxp->rux_runtime;
+ tu = cputick2usec(tu);
tt = ut + st + it;
if (tt == 0) {
st = 1;
tt = 1;
}
- tu = cputick2usec(ruxp->rux_runtime);
ptu = ruxp->rux_uu + ruxp->rux_su + ruxp->rux_iu;
- if (tu < ptu) {
- printf(
-"calcru: runtime went backwards from %ju usec to %ju usec for pid %d (%s)\n",
- (uintmax_t)ptu, (uintmax_t)tu, p->p_pid, p->p_comm);
- tu = ptu;
- }
if ((int64_t)tu < 0) {
printf("calcru: negative runtime of %jd usec for pid %d (%s)\n",
(intmax_t)tu, p->p_pid, p->p_comm);
@@ -784,6 +779,16 @@
uu = (tu * ut) / tt;
su = (tu * st) / tt;
iu = tu - uu - su;
+ if (tu < ptu) {
+ printf(
+"calcru: runtime went backwards from %ju usec to %ju usec for pid %d (%s)\n",
+ (uintmax_t)ptu, (uintmax_t)tu, p->p_pid, p->p_comm);
+ printf("u %ju:%ju/%ju s %ju:%ju/%ju i %ju:%ju/%ju\n",
+ (uintmax_t)ut, (uintmax_t)ruxp->rux_uu, uu,
+ (uintmax_t)st, (uintmax_t)ruxp->rux_su, su,
+ (uintmax_t)it, (uintmax_t)ruxp->rux_iu, iu);
+ tu = ptu;
+ }
#if 0
/* Enforce monotonicity. */
if (uu < ruxp->rux_uu || su < ruxp->rux_su || iu < ruxp->rux_iu) {
More information about the p4-projects
mailing list