Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1086311pxu; Wed, 6 Jan 2021 11:52:42 -0800 (PST) X-Google-Smtp-Source: ABdhPJx/75sk/yjtzmhBLjqwLrmfmRkUficSWxyXXRPnU6vJv/UNPyXtI8C4FaL5HEK3L5FdTrZc X-Received: by 2002:a17:907:2111:: with SMTP id qn17mr3767464ejb.525.1609962762352; Wed, 06 Jan 2021 11:52:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1609962762; cv=none; d=google.com; s=arc-20160816; b=0t0w9C6b8pXMWLrWnsL4oWkgv4DLG6zQ9h2D8X0NbWjumtlaE5mQkId9+k8JBDuFNY 446nUHDCg5ddDp8sINocHInUkfija1h6YZMHtHxopPu/rdixQyjWMc/INpjiwROk1nO7 DwjidokufQvJ8IxCld/KdNG2cUDhKyt1dWu+A3d9If7y20HvG5Fop8N29oC9tJ9sQDug LhVpjPM2v8tB3WBtpddxYvNDELLjSj+xDClhlsNRlzRUueN8cAwKbW7j4RpLjmef3Zlz /mjyzRv2MuzyKau/BSIZOepN/uHUlSFk4M0uGhNhznMsskfaPdBbFRF4Pjllpuhh/IrH sfbA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=2FPdr1CNG7z/7gPj8h6sWAHMN5f2vXJ4uowcH321lD0=; b=dGO7yQdBWEcxaExjR3V4VrnUIg9I9HUb+urDKORwJjm1I37Lxqa5F69R8rj1TTPNIJ D7H23sUCvduwotbcGjEaSrA+y5xdJHzNPnkJI/V1GaqVvrltneVOasy2Rg65CBir2JSc kvsGu+oenMsDuUoJETKzwm+RlIJGFc5d1f2GT2gaOW7cfGdfbgvhJamX1Txxlmkaqq04 rguGmMYWjzpRhTRMVfUUMJcQ5R2mpGmxQ326Lfhi5aZZ2c4jOoOxdaWqIJapGqXGJdXQ rchUKBSUbfknx4NiRL01ko1Zgz/tYdPVYcU0LAozKQne8Oyj54oYxxuBgs7SHB+f7hSw Y8uA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=JlGRz55g; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l18si1240385eje.178.2021.01.06.11.52.17; Wed, 06 Jan 2021 11:52:42 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=JlGRz55g; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726917AbhAFTv0 (ORCPT + 99 others); Wed, 6 Jan 2021 14:51:26 -0500 Received: from mail.kernel.org ([198.145.29.99]:46172 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726697AbhAFTvZ (ORCPT ); Wed, 6 Jan 2021 14:51:25 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id EFDE923131; Wed, 6 Jan 2021 19:50:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1609962645; bh=5kwh7EXq15V7c3k8dlsJ1An7qOaZRPcY0YlVfb4e0Q4=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=JlGRz55g7P3lJhKFgyXyXXHFWrlDGKKgiuVL75F6D5V0NJzNdck+Et37fd4VgVXgp /O+/fLAKYtYzd431NRrGH3/4gkfZAFNouEwd8R+D0Bmvwc3OdAY5O5DsfLNNH6l0Qt GCxq0Oh60XK9iDCK0baAm3nIF5YVYJyroAyQGk9Q= Date: Wed, 6 Jan 2021 11:50:44 -0800 From: Andrew Morton To: Roman Gushchin Cc: , Michal Hocko , Johannes Weiner , Shakeel Butt , , , Imran Khan Subject: Re: [PATCH] mm: memcg/slab: optimize objcg stock draining Message-Id: <20210106115044.c4393afa1ad61ef3f8db1d94@linux-foundation.org> In-Reply-To: <20210106042239.2860107-1-guro@fb.com> References: <20210106042239.2860107-1-guro@fb.com> X-Mailer: Sylpheed 3.5.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 5 Jan 2021 20:22:39 -0800 Roman Gushchin wrote: > Imran Khan reported a regression in hackbench results caused by the > commit f2fe7b09a52b ("mm: memcg/slab: charge individual slab objects > instead of pages"). How large was the regression? > --- a/mm/memcontrol.c > +++ b/mm/memcontrol.c > @@ -3122,9 +3122,7 @@ void __memcg_kmem_uncharge(struct mem_cgroup *memcg, unsigned int nr_pages) > if (!cgroup_subsys_on_dfl(memory_cgrp_subsys)) > page_counter_uncharge(&memcg->kmem, nr_pages); > > - page_counter_uncharge(&memcg->memory, nr_pages); > - if (do_memsw_account()) > - page_counter_uncharge(&memcg->memsw, nr_pages); > + refill_stock(memcg, nr_pages); > } IOW, which kernel version(s) should we be patching?