Re: [PATCH v3] memcg: cache obj_stock by memcg, not by objcg pointer

From: Shakeel Butt

Date: Tue May 19 2026 - 16:13:22 EST


On Wed, May 20, 2026 at 12:00:16AM +0900, Harry Yoo wrote:
>
>
[...]
> >
> > The full clean solution might take one more cycle and I think we can not just
> > ignore 67% regression on 7.1.
>
> That is valid point, unfortunately.
>
> One more thing I have to ask... for v7.1, wouldn't it be a safer option to
> revert the per-node object change and re-introduce it once we have a cleaner
> solution?

The issue with that revert is that we reintroduce all node lru locking in the
objcg reparenting path.

>
> This change was introduced in v5, but the implementation before v4 had been
> exposed in -next for a while, and I think we don't have enough justification
> to keep the per-node objcgs change, at least for v7.1, given that we have an
> unexpected last-minute regression and
> correctness concerns (albeit slight).

I am waiting for Oliver to test the multi-objcg patch I sent. If that also
resolves the regression then we have one more option i.e. backport that to 7.1
to fix the regression.

So to summarize, for future kernels we will be having multi-objcg in some form.
For 7.1, we have to decide between (1) do nothing (2) this patch or (3) backport
the multi-objcg path to 7.1.

Andrew, please don't send this patch to Linus until we decide on the option.