[PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-09-25 Thread Tejun Heo
There are a couple interface issues which can be addressed in cgroup2 interface. * Stats from cpuacct being reported separately from the cpu stats. * Use of different time units. Writable control knobs use microseconds, some stat fields use nanoseconds while other cpuacct stat fields use

[PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-09-25 Thread Tejun Heo
There are a couple interface issues which can be addressed in cgroup2 interface. * Stats from cpuacct being reported separately from the cpu stats. * Use of different time units. Writable control knobs use microseconds, some stat fields use nanoseconds while other cpuacct stat fields use

[PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-11 Thread Tejun Heo
There are a couple interface issues which can be addressed in cgroup2 interface. * Stats from cpuacct being reported separately from the cpu stats. * Use of different time units. Writable control knobs use microseconds, some stat fields use nanoseconds while other cpuacct stat fields use

[PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-11 Thread Tejun Heo
There are a couple interface issues which can be addressed in cgroup2 interface. * Stats from cpuacct being reported separately from the cpu stats. * Use of different time units. Writable control knobs use microseconds, some stat fields use nanoseconds while other cpuacct stat fields use

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-02 Thread Tejun Heo
Hello, Peter. On Wed, Aug 02, 2017 at 06:05:11PM +0200, Peter Zijlstra wrote: > > * The stat file is sampling based and the usage files are calculated > > from actual scheduling events. Is this because the latter is more > > accurate? > > So I actually don't know the history of this stuff

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-02 Thread Tejun Heo
Hello, Peter. On Wed, Aug 02, 2017 at 06:05:11PM +0200, Peter Zijlstra wrote: > > * The stat file is sampling based and the usage files are calculated > > from actual scheduling events. Is this because the latter is more > > accurate? > > So I actually don't know the history of this stuff

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-02 Thread Peter Zijlstra
On Wed, Aug 02, 2017 at 08:41:35AM -0700, Tejun Heo wrote: > > Not entirely sure I follow, we currently only update the current cgroup > > and its immediate parents, no? Or are you looking to only account into > > the current cgroup and propagate into the parents on reading? > > Yeah, shifting

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-02 Thread Peter Zijlstra
On Wed, Aug 02, 2017 at 08:41:35AM -0700, Tejun Heo wrote: > > Not entirely sure I follow, we currently only update the current cgroup > > and its immediate parents, no? Or are you looking to only account into > > the current cgroup and propagate into the parents on reading? > > Yeah, shifting

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-02 Thread Tejun Heo
Hello, Peter. On Tue, Aug 01, 2017 at 11:40:38PM +0200, Peter Zijlstra wrote: > > * On cgroup2, there is only one hierarchy. It'd be great to have > > basic resource accounting enabled by default on all cgroups. Note > > that we couldn't do that on v1 because there could be any number of >

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-02 Thread Tejun Heo
Hello, Peter. On Tue, Aug 01, 2017 at 11:40:38PM +0200, Peter Zijlstra wrote: > > * On cgroup2, there is only one hierarchy. It'd be great to have > > basic resource accounting enabled by default on all cgroups. Note > > that we couldn't do that on v1 because there could be any number of >

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-01 Thread Peter Zijlstra
On Tue, Aug 01, 2017 at 01:17:45PM -0700, Tejun Heo wrote: > > What about the whole double accounting thing? Because currently cpuacct > > and cpu do a fair bit of duplication. It would be very good to get rid > > of that. > > I'm not that sure at this point. Here are my current thoughts on >

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-01 Thread Peter Zijlstra
On Tue, Aug 01, 2017 at 01:17:45PM -0700, Tejun Heo wrote: > > What about the whole double accounting thing? Because currently cpuacct > > and cpu do a fair bit of duplication. It would be very good to get rid > > of that. > > I'm not that sure at this point. Here are my current thoughts on >

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-01 Thread Tejun Heo
Hello, Peter. On Sat, Jul 29, 2017 at 11:17:07AM +0200, Peter Zijlstra wrote: > > * "cpu.shares" is replaced with "cpu.weight" and operates on the > > standard scale defined by CGROUP_WEIGHT_MIN/DFL/MAX (1, 100, 1). > > The weight is scaled to scheduler weight so that 100 maps to 1024 > >

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-08-01 Thread Tejun Heo
Hello, Peter. On Sat, Jul 29, 2017 at 11:17:07AM +0200, Peter Zijlstra wrote: > > * "cpu.shares" is replaced with "cpu.weight" and operates on the > > standard scale defined by CGROUP_WEIGHT_MIN/DFL/MAX (1, 100, 1). > > The weight is scaled to scheduler weight so that 100 maps to 1024 > >

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-07-29 Thread Peter Zijlstra
On Thu, Jul 20, 2017 at 02:48:08PM -0400, Tejun Heo wrote: > There are a couple interface issues which can be addressed in cgroup2 > interface. > > * Stats from cpuacct being reported separately from the cpu stats. > > * Use of different time units. Writable control knobs use > microseconds,

Re: [PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-07-29 Thread Peter Zijlstra
On Thu, Jul 20, 2017 at 02:48:08PM -0400, Tejun Heo wrote: > There are a couple interface issues which can be addressed in cgroup2 > interface. > > * Stats from cpuacct being reported separately from the cpu stats. > > * Use of different time units. Writable control knobs use > microseconds,

[PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-07-20 Thread Tejun Heo
There are a couple interface issues which can be addressed in cgroup2 interface. * Stats from cpuacct being reported separately from the cpu stats. * Use of different time units. Writable control knobs use microseconds, some stat fields use nanoseconds while other cpuacct stat fields use

[PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2017-07-20 Thread Tejun Heo
There are a couple interface issues which can be addressed in cgroup2 interface. * Stats from cpuacct being reported separately from the cpu stats. * Use of different time units. Writable control knobs use microseconds, some stat fields use nanoseconds while other cpuacct stat fields use

[PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2016-08-05 Thread Tejun Heo
>From ed6d93036ec930cb774da10b7c87f67905ce71f1 Mon Sep 17 00:00:00 2001 From: Tejun Heo Date: Fri, 11 Mar 2016 07:31:23 -0500 While the cpu controller doesn't have any functional problems, there are a couple interface issues which can be addressed in the v2 interface. * cpuacct

[PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2016-08-05 Thread Tejun Heo
>From ed6d93036ec930cb774da10b7c87f67905ce71f1 Mon Sep 17 00:00:00 2001 From: Tejun Heo Date: Fri, 11 Mar 2016 07:31:23 -0500 While the cpu controller doesn't have any functional problems, there are a couple interface issues which can be addressed in the v2 interface. * cpuacct being a separate

[PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2016-01-05 Thread Tejun Heo
While the cpu controller doesn't have any functional problems, there are a couple interface issues which can be addressed in the v2 interface. * cpuacct being a separate controller. This separation is artificial and rather pointless as demonstrated by most use cases co-mounting the two

[PATCH 2/2] sched: Implement interface for cgroup unified hierarchy

2016-01-05 Thread Tejun Heo
While the cpu controller doesn't have any functional problems, there are a couple interface issues which can be addressed in the v2 interface. * cpuacct being a separate controller. This separation is artificial and rather pointless as demonstrated by most use cases co-mounting the two