Re: Interrupt routine usage not shown by top in 8.0

From: Ed Maste <emaste_at_freebsd.org>
Date: Mon, 23 Mar 2009 11:23:36 -0400
On Sun, Mar 22, 2009 at 03:06:52PM -0700, Barney Cordoba wrote:

> I set up a little task that basically does:
> 
> foo_task(){
> 
> while(1){
>   foo_doreceive();
>   pause("foo",1);
> }
> 
> }
> 
> which wakes hz times per second in 7 and hz/2 times per second in
> 8. The same accounting issue exists for this case, as I have it bridging
> 400K pps and usage shows 0 most of the time. I've added some firewall 
> rules which should substantially increase the load, but still no usage.
> If I really hammer it, like 600Kpps, it starts registering 30% usage,
> with no ramp up in between. I suppose it could be just falling out of the
> cache or something, but it doesn't seem realistic.
> 
> Is there some hack I can implement to make sure a task is 
> accounted for, or some other way to monitor its usage?

There are aliasing issues caused by driving the scheduler and the stat
clock from the same source.  It's particularly bad in our environment
at work, so we reverted the clock sharing, and went back to using the
i8254 for stats.

If you're interested in giving this a try, I've posted the patch at
<http://people.freebsd.org/~emaste/patches/statclock.diff>.  This is
against 6.1 and might have some other minor changes, but the diff is
small enough that you could easily apply it by hand as well.  If you do
try it out let me know what you find.

-Ed
Received on Mon Mar 23 2009 - 15:45:32 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:44 UTC