lkml.org 
[lkml]   [2009]   [Mar]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Process accounting in interrupt diabled cases
On Sat, 07 Mar 2009 00:59:33 -0800
Alok Kataria <akataria@vmware.com> wrote:

> Yes that's alright, all that time when vcpu was idle and scheduled out
> will anyways be accounted as idle time, as mentioned in my earlier mail
> ( and if my understanding is not wrong) this is handled by
> tick_nohz_restart_sched_tick.
>
> But i was talking about a case, where we have this code
> local_irq_disable()
> some_work()
> local_irq_enable()
>
> If this some_work() executed for say 2 ticks, shouldn't the process
> executing this be accounted 2 ticks of system time ? According to my
> understanding, we will account a single tick for this, right ?

Don't know too much about x86 and Xen but on s390 the tick is just a
convenient way to transfer the accumulated cpu time to the process and
the cpustat fields. The cpu time that has been used is determined by
the cpu timer. This would still work without any ticks at all, although
then you'd have to wait for the next context switch until the
accumulated cpu time gets visible in the process and cpustat.
In short: the above example just works fine for us.

--
blue skies,
Martin.

"Reality continues to ruin my life." - Calvin.



\
 
 \ /
  Last update: 2009-03-11 09:53    [W:0.078 / U:1.352 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site