Hi Aubrey,

Li, Aubrey wrote:
> Here is a dtrace script attached, and the output is as follows:
> #./test.d
> Dtrace: script './test.d' matched 5 probes
> CPU   ID                      FUNCTION:NAME
> 1     91095                   :tick-5sec      1, profile`profile_tick
> , 1
>       10,     genunix`deadman , 1
>       501,    unix`cbe_hres_tick, 1
>       501,    genunix`clock, 3
>       501,    genunix`cyclic_timer , 3
>       501,    pil = 10
> The probe in av_dispatch_softvect() is fired 500 times per 5-second.
> But each of the three cyclic customers are called 500 times per
> 5-second.
>
> Does this mean we should count cyclic event as 500 times rather than
> 1500 times?
>   

That's a great observation, and a great question. It sounds like the 
firings of the 3 events are being batch processed, which is made 
possible since they all fire at the same rate. In this case, it may well 
be that there is one CPU wakeup per 3 events. But as a consumer of the 
tool what I really want to know is which cyclics are firing, so that I 
can go and figure out how to make them fire less often, or if they can 
be eliminated all together. Showing only the soft interrupt events would 
give a more accurate count of how often the CPU is waking up...but I 
think it's more critical to convey (in terms of facilitating power 
efficiency work) are the names of the cyclics and callouts. Similarly, 
with respect to user software applications that wake up 
peroidically...it might be that if two applications wakeup at about the 
same time, they might run back to back without the CPU halting in 
between...but even so I think what what's really interesting is which 
applications are waking up and how often. The fact that they can be 
batched seems like more of an implementation artifact. What do you think?

Thanks,
-Eric


Reply via email to