Re: Updated rusage patch



Bruce Evans wrote:
On Fri, 1 Jun 2007, Jeff Roberson wrote:

Please grep for statclock in threadlock.diff. This removes time_lock from statclock all together and protects the whole thing with thread_lock(). With this change all cpus can execute statclock() concurrently with sched_smp.c. This patch also has fixes for locking ruxagg() as well as asserts. It does not yet protect the ru copying in exit(). I want to figure out the synchronization issues with wait first.

I don't want to get involved reviewing another large[r] patch.

A bug turned up with the previously committed patches: the swapper
process is now shown as having a runtime of 40-47 seconds after
booting (and never changes after that), but I don't use swapping and
this process has always been shown as having a runtime of 0 seconds
before.

The bug seems to be that proc0_post() doesn't know anything about the
rusage fields in the thread struct. Until recently, it was only missing
initialization of td_*ticks. Now it is missing initialization of
td_runtime too, so the bug is more obvious.

Yes, I always wondered why proc0_post() doesn't initialize [s,i,u]ticks too.
However, could you please give a look and a try to this patch:
http://users.gufi.org/~rookie/works/patches/schedlock/proc_post.diff

and see if it solves your problem.

Thanks,
Attilio
_______________________________________________
freebsd-arch@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-arch
To unsubscribe, send any mail to "freebsd-arch-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: Updated rusage patch
    ... statclock all together and protects the whole thing with thread_lock. ... With this change all cpus can execute statclock() concurrently with sched_smp.c. ... initialization of td_*ticks. ... The rusage fields may or may not be garbage when proc0_postruns, ...
    (freebsd-arch)
  • Re: [PATCH] Reduce __print_symbol/sprint_symbol stack usage.
    ... This is my second stab at solving the "stack over flow due to ... this patch is creates less noise then the previous one. ... Try to keep the declarations of a lock, and the data that it protects, ...
    (Linux-Kernel)
  • Re: Why no patch for the .wmf problem?
    ... possibly one of the fastest patches they've ever released. ... you as well as it protects you from any other virus. ... >>> I find the lack of direct communication from Microsoft and the lack ... >>> of a definate target date for a patch to be unacceptable. ...
    (microsoft.public.security)
  • Re: Sasser worm and fear of KB835732 patch
    ... You should install the patch. ... > protects against all current versions of this worm... ... Am I safe the with the NAV ...
    (microsoft.public.windowsupdate)