lkml.org 
[lkml]   [2019]   [Jan]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/2] mm: Consider subtrees in memory.events
On Mon 28-01-19 06:54:07, Tejun Heo wrote:
> Hello,
>
> On Mon, Jan 28, 2019 at 03:52:10PM +0100, Michal Hocko wrote:
> > > All .events files generate aggregated stateful notifications. For
> > > anyone to do anything, they'd have to remember the previous state to
> > > identify what actually happened. Being hierarchical, it'd of course
> > > need to walk down when an event triggers.
> >
> > And how do you do that in a raceless fashion?
>
> Hmm... I'm having trouble imagining why this would be a problem. How
> would it race?

How do you make an atomic snapshot of the hierarchy state? Or you do
not need it because event counters are monotonic and you are willing to
sacrifice some lost or misinterpreted events? For example, you receive
an oom event while the two children increase the oom event counter. How
do you tell which one was the source of the event and which one is still
pending? Or is the ordering unimportant in general?

I can imagine you can live with this model, but having a hierarchical
reporting without a source of the event just sounds too clumsy from my
POV. But I guess this is getting tangent to the original patch.
--
Michal Hocko
SUSE Labs

\
 
 \ /
  Last update: 2019-01-28 16:19    [W:0.240 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site