Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp653106imm; Wed, 8 Aug 2018 03:28:56 -0700 (PDT) X-Google-Smtp-Source: AA+uWPzfaDijOGseAHyPinOMCPBQjs+HBjyPfJvKPcR9t6VA49I42V+CvvRuMsLudZFTpRZFlSnn X-Received: by 2002:a63:c60:: with SMTP id 32-v6mr2018538pgm.155.1533724136898; Wed, 08 Aug 2018 03:28:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533724136; cv=none; d=google.com; s=arc-20160816; b=Yso5OwWVI1yes7LLm1yvlSD69Gt0JXm7azBj8XdXCSv4AnAr3I30Ig1FR4T36QvCg2 7KAQYj3pao7VOzrRdYl1IIPC7wjyPI6ykifbmElU1gW4+YJ7ioYGtpxWj623JyjY0lIK LwaFDgtpHZOB8D43enmBzv8uFFsaRMYjS4uSsEA53bOPvxiwfqya3TDVt1TUUxJ5aI2j 2yJnT+D3oivHRZM4F/mPaXRfPWbZCAs5vIF384eTGvC1HAwUXMxkKQipLsJ7ADt+rNOo mh25He6gxbon9QUpG6BL4zEEjvPCvL4dOFQeIXhHAe+arYjcKgWZuYC+dvlFE5TCKMMT S0GA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=ofZK0liQhYvmwg5ENCtLv0gHJnXVS7rXXGhS3j/L8/Q=; b=BwPI+Ry2olsnRA7Cq9IQawf8oX8/OB8k2X4APjGpU+IUz3DMzGJMxJO3fgqbWPPcF2 0+QYalM4penHLpb8hjAbPdirMJDQmpwU8goZNaPU/w+hkQ///qospCpZgxBvTiVNXthA KHISMZFtkyBkg7rKhhzucmGkGDaP0OMvrmo9s+Lv5sQ5wKZMCLWMnVUkMhOwtKg2ekfv 5ZvByvgv+WJajGTV0INdK0mv19JW5ZAgMDNji7HM5uTgky8waaEh5y4T0XWEVXvR7SXC pHjPxchKtIKysRQ7eAMthr1uiVWjFCoqd8BJJOHj/GkmU+Paks7vTo8OOXrt+iX3e9mg hK1Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p67-v6si3670054pfg.295.2018.08.08.03.28.42; Wed, 08 Aug 2018 03:28:56 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727062AbeHHMqn (ORCPT + 99 others); Wed, 8 Aug 2018 08:46:43 -0400 Received: from mx2.suse.de ([195.135.220.15]:56422 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726643AbeHHMqn (ORCPT ); Wed, 8 Aug 2018 08:46:43 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 5D562AD09; Wed, 8 Aug 2018 10:27:37 +0000 (UTC) Date: Wed, 8 Aug 2018 12:27:34 +0200 From: Michal Hocko To: Kirill Tkhai Cc: akpm@linux-foundation.org, gregkh@linuxfoundation.org, rafael@kernel.org, viro@zeniv.linux.org.uk, darrick.wong@oracle.com, paulmck@linux.vnet.ibm.com, josh@joshtriplett.org, rostedt@goodmis.org, mathieu.desnoyers@efficios.com, jiangshanlai@gmail.com, hughd@google.com, shuah@kernel.org, robh@kernel.org, ulf.hansson@linaro.org, aspriel@gmail.com, vivek.gautam@codeaurora.org, robin.murphy@arm.com, joe@perches.com, heikki.krogerus@linux.intel.com, sfr@canb.auug.org.au, vdavydov.dev@gmail.com, chris@chris-wilson.co.uk, penguin-kernel@I-love.SAKURA.ne.jp, aryabinin@virtuozzo.com, willy@infradead.org, ying.huang@intel.com, shakeelb@google.com, jbacik@fb.com, mingo@kernel.org, mhiramat@kernel.org, linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH RFC 01/10] rcu: Make CONFIG_SRCU unconditionally enabled Message-ID: <20180808102734.GH27972@dhcp22.suse.cz> References: <153365347929.19074.12509495712735843805.stgit@localhost.localdomain> <153365625652.19074.8434946780002619802.stgit@localhost.localdomain> <20180808072040.GC27972@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [CC Josh - the whole series is http://lkml.kernel.org/r/153365347929.19074.12509495712735843805.stgit@localhost.localdomain] On Wed 08-08-18 13:17:44, Kirill Tkhai wrote: > On 08.08.2018 10:20, Michal Hocko wrote: > > On Tue 07-08-18 18:37:36, Kirill Tkhai wrote: > >> This patch kills all CONFIG_SRCU defines and > >> the code under !CONFIG_SRCU. > > > > The last time somebody tried to do this there was a pushback due to > > kernel tinyfication. So this should really give some numbers about the > > code size increase. Also why can't we make this depend on MMU. Is > > anybody else than the reclaim asking for unconditional SRCU usage? > > I don't know one. The size numbers (sparc64) are: > > $ size image.srcu.disabled > text data bss dec hex filename > 5117546 8030506 1968104 15116156 e6a77c image.srcu.disabled > $ size image.srcu.enabled > text data bss dec hex filename > 5126175 8064346 1968104 15158625 e74d61 image.srcu.enabled > The difference is: 15158625-15116156 = 42469 ~41Kb > > Please, see the measurement details to my answer to Stephen. > > > Btw. I totaly agree with Steven. This is a very poor changelog. It is > > trivial to see what the patch does but it is far from clear why it is > > doing that and why we cannot go other ways. > We possibly can go another way, and there is comment to [2/10] about this. > Percpu rwsem may be used instead, the only thing, it is worse, is it will > make shrink_slab() wait unregistering shrinkers, while srcu-based > implementation does not require this. Well, if unregisterring doesn't do anything subtle - e.g. an allocation or take locks which depend on allocation - and we can guarantee that then blocking shrink_slab shouldn't be a big deal. It is subtle though. Maybe subtle enough to make unconditional SRCU worth it. This all should be in the changelog though. > This may be not a big problem. > But, if SRCU is real problem for embedded people, I really don't want they > hate me in the future because of this, so please CC someone if you know :) I guess Josh was trying to pursue kernel tinification. -- Michal Hocko SUSE Labs