From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.4 required=3.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_IN_DEF_DKIM_WL autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2A78DC2D0EF for ; Fri, 17 Apr 2020 16:41:19 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id DE35522209 for ; Fri, 17 Apr 2020 16:41:18 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="A+CXQpwU" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org DE35522209 Authentication-Results: mail.kernel.org; dmarc=fail (p=reject dis=none) header.from=google.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 60B678E0035; Fri, 17 Apr 2020 12:41:18 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 5BD138E0023; Fri, 17 Apr 2020 12:41:18 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4F9458E0035; Fri, 17 Apr 2020 12:41:18 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0068.hostedemail.com [216.40.44.68]) by kanga.kvack.org (Postfix) with ESMTP id 3546A8E0023 for ; Fri, 17 Apr 2020 12:41:18 -0400 (EDT) Received: from smtpin05.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id ED1D8180ACC36 for ; Fri, 17 Apr 2020 16:41:17 +0000 (UTC) X-FDA: 76717912194.05.base63_629e134f1a33d X-HE-Tag: base63_629e134f1a33d X-Filterd-Recvd-Size: 3970 Received: from mail-lf1-f68.google.com (mail-lf1-f68.google.com [209.85.167.68]) by imf10.hostedemail.com (Postfix) with ESMTP for ; Fri, 17 Apr 2020 16:41:17 +0000 (UTC) Received: by mail-lf1-f68.google.com with SMTP id w145so2324787lff.3 for ; Fri, 17 Apr 2020 09:41:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=KReP0BQ7R9kDWKVN2qYXZOSpqxd/RqsatXVhR8Hp+6M=; b=A+CXQpwUauVcRxKfmCkhrY+lO8YU2Of5TvIiYGM8+ZPQlQxaAlRsouUQvYIVuYEfo9 tiFjNYW4sA8i7jeVhSr4CGPhlKpq3zNblY0JIHYp7mUhuPZ+nr52IAgv8ozW5UO4aCFr 1xyOETsWR7Hu1Jy0boQWlTBoROvOK1qxhWVumIDprKpG6rUXf7Il+1RCub37qYG7s0i6 vTd0fKn7UlV78sU6nxXxaEMbfUVFHOuAWNgVkcvgiz+OZCP4AOGXFdg2IzaPl2wF02Y5 pvnB1XKmzAQb+B+OhYk2vHB5o71IRkdE8KQBO1A86zGoCa6jppakQhH1Tu7QZ7MRnUrh ufqg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=KReP0BQ7R9kDWKVN2qYXZOSpqxd/RqsatXVhR8Hp+6M=; b=GcCxcMxH+OvVP15mN0c73JJyFwLAdV6gPl9QEcbWAKT3KctsHajg+JS79EJBkXGhyl sot6ZLp+Tun2c3OztPQlT34NrQcIf/aUBkupNJYMmPLJ3llbJjHbGGc+8r1KtVV+nq5Z 30CrcS+awZgvz2BoMPWTq4lEZnOedxA4f4JSjIY3Ptze3CHbLtS+tEvU9/aD3+KFgWrx 7XXE7XINh+J5ko1UL/op73pRVEpXLNjDxVZCfopfjlVe5s2jJC+ZEDwXHjjK9eIcTH6L AqfAu7CF3D7ICsxp1nb4CEaGaBerfkmoeq4otSgJFfFwTtx7w4BcpCL4Yru36zPqmaZE sikQ== X-Gm-Message-State: AGi0PuZh4H9crzrseGAOdUu0UrwsXJhCnaUjCcA7fByaiRcWpnuY4Nby f7BijIbTv4kYOMqv8yVWDZ2RnfYGiRIMOrnKzBhYlw== X-Google-Smtp-Source: APiQypKsYQEjmk9jge5Ap9/TOaSDMsXV1vm37kJTAvdwzjqdzMAFBfGpUon2DIbYZM/d42XY8I0UZtNyvCwr2JhoxUQ= X-Received: by 2002:a19:5206:: with SMTP id m6mr2620913lfb.33.1587141675828; Fri, 17 Apr 2020 09:41:15 -0700 (PDT) MIME-Version: 1.0 References: <1587134624-184860-1-git-send-email-alex.shi@linux.alibaba.com> <20200417155317.GS26707@dhcp22.suse.cz> In-Reply-To: <20200417155317.GS26707@dhcp22.suse.cz> From: Shakeel Butt Date: Fri, 17 Apr 2020 09:41:04 -0700 Message-ID: Subject: Re: [PATCH 1/2] memcg: folding CONFIG_MEMCG_SWAP as default To: Michal Hocko Cc: Alex Shi , Andrew Morton , Johannes Weiner , Linux MM , Cgroups Content-Type: text/plain; charset="UTF-8" X-Bogosity: Ham, tests=bogofilter, spamicity=0.000001, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Fri, Apr 17, 2020 at 9:03 AM Michal Hocko wrote: > > On Fri 17-04-20 22:43:43, Alex Shi wrote: > > This patch fold MEMCG_SWAP feature into kernel as default function. That > > required a short size memcg id for each of page. As Johannes mentioned > > > > "the overhead of tracking is tiny - 512k per G of swap (0.04%).' > > > > So all swapout page could be tracked for its memcg id. > > I am perfectly OK with dropping the CONFIG_MEMCG_SWAP. The code that is > guarded by it is negligible and the resulting code is much easier to > read so no objection on that front. I just do not really see any real > reason to flip the default for cgroup v1. Why do we want/need that? > Yes, the changelog is lacking the motivation of this change. This is proposed by Johannes and I was actually expecting the patch from him. The motivation is to make the things simpler for per-memcg LRU locking and workingset for anon memory (Johannes has described these really well, lemme find the email). If we keep the differentiation between cgroup v1 and v2, then there is actually no point of this cleanup as per-memcg LRU locking and anon workingset still has to handle the !do_swap_account case. Shakeel