From: "KAMEZAWA Hiroyuki" <kamezawa.hiroyu@jp.fujitsu.com>
To: "Dhaval Giani" <dhaval@linux.vnet.ibm.com>
Cc: "KAMEZAWA Hiroyuki" <kamezawa.hiroyu@jp.fujitsu.com>,
"Ken Chen" <kenchen@google.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"menage@google.com" <menage@google.com>,
"lizf@cn.fujitsu.com" <lizf@cn.fujitsu.com>,
"balbir@linux.vnet.ibm.com" <balbir@linux.vnet.ibm.com>,
mingo@elte.hu,
"akpm@linux-foundation.org" <akpm@linux-foundation.org>
Subject: Re: [PATCH] change cpuacct usage percpu format v2
Date: Sat, 28 Feb 2009 18:37:08 +0900 (JST) [thread overview]
Message-ID: <0c61acc4a0951c46262d52a8eec4db32.squirrel@webmail-b.css.fujitsu.com> (raw)
In-Reply-To: <20090228092431.GA22310@linux.vnet.ibm.com>
Dhaval Giani wrote:
> On Sat, Feb 28, 2009 at 02:25:22PM +0900, KAMEZAWA Hiroyuki wrote:
>> Dhaval Giani wrote:
>> > On Sat, Feb 28, 2009 at 09:42:17AM +0900, KAMEZAWA Hiroyuki wrote:
>> >> KAMEZAWA Hiroyuki wrote:
>> >> BTW, current interface to reset cpuacct (write ops) just reset
>> >> specified level of cpuacct and will not clear other hierarchical
>> levels.
>> >> Doesn't this behavior confuse software ?
>> >>
>> >
>> > hmmm. This got missed when we introduced hierarchy. But I wonder if it
>> > is needed?
>> >
>> IIUC, cpuacct.usage just shows sum of itself and all children's usage
>> and
>> its own usage can be calclated by reading all usage of hierarchy.
>> So, reset ops seems to be a bit broken.
>> And by this, parent's usage can be smaller than children.
>>
>
> Actually now that I think about it, it does make sense, but when I
> started implementing it, a question popped up, if we reset a child's
> counter, then the parent is going to have a much greater usage than the
> sum of the children. I wonder if this behavior is fine?
>
As far as the user remembers he did reset...
>> How about adding limitation as "you can clear usage only when there are
>> no
>> children" ? Maybe not very strange limitaton under hierarchical system.
>>
>
> Just the question I asked. Beyond that I don't think we should have such a
> limitation on reset.
>
Ok, I don't have strong requirements. I'll recomend users that you should
reset all children(hierarchy) at the same time.
Maybe no problem if we have private-usage counter....but it means one more
percpu array...
Thanks,
-Kame
prev parent reply other threads:[~2009-02-28 9:37 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-27 5:05 [PATCH] change cpuacct usage percpu format KAMEZAWA Hiroyuki
2009-02-27 6:39 ` Balbir Singh
2009-02-27 6:55 ` KAMEZAWA Hiroyuki
2009-02-27 7:01 ` Balbir Singh
2009-02-27 7:03 ` Li Zefan
2009-02-27 7:05 ` KAMEZAWA Hiroyuki
2009-02-27 7:29 ` [PATCH] change cpuacct usage percpu format v2 KAMEZAWA Hiroyuki
2009-02-27 7:55 ` Paul Menage
2009-02-27 8:02 ` KAMEZAWA Hiroyuki
2009-02-27 20:13 ` Ken Chen
2009-02-27 23:34 ` KAMEZAWA Hiroyuki
2009-02-28 0:00 ` Ken Chen
2009-02-28 0:14 ` KAMEZAWA Hiroyuki
2009-02-28 0:42 ` KAMEZAWA Hiroyuki
2009-02-28 1:11 ` Dhaval Giani
2009-02-28 5:25 ` KAMEZAWA Hiroyuki
2009-02-28 9:24 ` Dhaval Giani
2009-02-28 9:37 ` KAMEZAWA Hiroyuki [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=0c61acc4a0951c46262d52a8eec4db32.squirrel@webmail-b.css.fujitsu.com \
--to=kamezawa.hiroyu@jp.fujitsu.com \
--cc=akpm@linux-foundation.org \
--cc=balbir@linux.vnet.ibm.com \
--cc=dhaval@linux.vnet.ibm.com \
--cc=kenchen@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lizf@cn.fujitsu.com \
--cc=menage@google.com \
--cc=mingo@elte.hu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome