lkml.org 
[lkml]   [2023]   [Feb]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] mm/memcg: Skip high limit check in root memcg
On Tue 21-02-23 22:21:45, Haifeng Xu wrote:
[...]
> >> The test result show that with or without the patch, the time taken is almost the same.
> >
> > This is in line with my expectation. So the question is whether the
> > additional check is really worth it.
>
> This patch doesn't bring any obvious benifit or harm, but the high
> limit check in root memcg seems a little weird. Maybe we can add this
> check

Well, I do not see the code to look weird TBH. There is nothing wrong in
doing the check for the root memcg. It is a bit pointless but it is not
incorrect.

> It all depends on your viewpoint.

From my POV, I prefer changes that either fix something (correctness
issue or a performance issue/improvement) or improve readbility. The
check doesn't fix anything and I am not convinced about an improved
readabilit either.

Thanks for the patch anyway!
--
Michal Hocko
SUSE Labs

\
 
 \ /
  Last update: 2023-03-27 00:30    [W:0.059 / U:0.648 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site