Re: [PATCH 1/3] mm: memcontrol: Use cgroup_rstat for event accounting

2018-04-04 Thread Tejun Heo
Hello, On Wed, Apr 04, 2018 at 04:34:47PM +0200, Michal Hocko wrote: > > > The lazy updates are neat, but I'm a little concerned at the memory > > > footprint. On a 64-cpu machine for example, this adds close to 9000 > > > words to struct mem_cgroup. And we really only need the accuracy for > > >

Re: [PATCH 1/3] mm: memcontrol: Use cgroup_rstat for event accounting

2018-04-04 Thread Tejun Heo
Hello, On Wed, Apr 04, 2018 at 04:34:47PM +0200, Michal Hocko wrote: > > > The lazy updates are neat, but I'm a little concerned at the memory > > > footprint. On a 64-cpu machine for example, this adds close to 9000 > > > words to struct mem_cgroup. And we really only need the accuracy for > > >

Re: [PATCH 1/3] mm: memcontrol: Use cgroup_rstat for event accounting

2018-04-04 Thread Michal Hocko
On Wed 04-04-18 10:18:50, Johannes Weiner wrote: > On Wed, Apr 04, 2018 at 10:08:55AM -0400, Johannes Weiner wrote: > > On Sat, Mar 24, 2018 at 09:08:59AM -0700, Tejun Heo wrote: > > > @@ -91,6 +91,9 @@ struct mem_cgroup_stat_cpu { > > > unsigned long events[MEMCG_NR_EVENTS]; > > > unsigned

Re: [PATCH 1/3] mm: memcontrol: Use cgroup_rstat for event accounting

2018-04-04 Thread Michal Hocko
On Wed 04-04-18 10:18:50, Johannes Weiner wrote: > On Wed, Apr 04, 2018 at 10:08:55AM -0400, Johannes Weiner wrote: > > On Sat, Mar 24, 2018 at 09:08:59AM -0700, Tejun Heo wrote: > > > @@ -91,6 +91,9 @@ struct mem_cgroup_stat_cpu { > > > unsigned long events[MEMCG_NR_EVENTS]; > > > unsigned

Re: [PATCH 1/3] mm: memcontrol: Use cgroup_rstat for event accounting

2018-04-04 Thread Johannes Weiner
On Wed, Apr 04, 2018 at 10:08:55AM -0400, Johannes Weiner wrote: > On Sat, Mar 24, 2018 at 09:08:59AM -0700, Tejun Heo wrote: > > @@ -91,6 +91,9 @@ struct mem_cgroup_stat_cpu { > > unsigned long events[MEMCG_NR_EVENTS]; > > unsigned long nr_page_events; > > unsigned long

Re: [PATCH 1/3] mm: memcontrol: Use cgroup_rstat for event accounting

2018-04-04 Thread Johannes Weiner
On Wed, Apr 04, 2018 at 10:08:55AM -0400, Johannes Weiner wrote: > On Sat, Mar 24, 2018 at 09:08:59AM -0700, Tejun Heo wrote: > > @@ -91,6 +91,9 @@ struct mem_cgroup_stat_cpu { > > unsigned long events[MEMCG_NR_EVENTS]; > > unsigned long nr_page_events; > > unsigned long

Re: [PATCH 1/3] mm: memcontrol: Use cgroup_rstat for event accounting

2018-04-04 Thread Johannes Weiner
On Sat, Mar 24, 2018 at 09:08:59AM -0700, Tejun Heo wrote: > @@ -91,6 +91,9 @@ struct mem_cgroup_stat_cpu { > unsigned long events[MEMCG_NR_EVENTS]; > unsigned long nr_page_events; > unsigned long targets[MEM_CGROUP_NTARGETS]; > + > + /* for cgroup rstat delta calculation */

Re: [PATCH 1/3] mm: memcontrol: Use cgroup_rstat for event accounting

2018-04-04 Thread Johannes Weiner
On Sat, Mar 24, 2018 at 09:08:59AM -0700, Tejun Heo wrote: > @@ -91,6 +91,9 @@ struct mem_cgroup_stat_cpu { > unsigned long events[MEMCG_NR_EVENTS]; > unsigned long nr_page_events; > unsigned long targets[MEM_CGROUP_NTARGETS]; > + > + /* for cgroup rstat delta calculation */