Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp3020221pxb; Tue, 24 Aug 2021 13:07:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw0DtASh2w46nHPpR4AtRa2lJFrNW9PzplgxRTx/ADPrUDQr5ZMmQ0SzhwTPe5FtdJt8neR X-Received: by 2002:a17:906:7716:: with SMTP id q22mr43355616ejm.457.1629835674108; Tue, 24 Aug 2021 13:07:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1629835674; cv=none; d=google.com; s=arc-20160816; b=RfWGx+nlKqpgkPod4JqEQtkehwwVNQBKULJ5LScuBE3eAu+bPIMTdBALyTATiabgko QaDC31mqbsjJy3+MwX6HIUKF5aCu7yo8byXaYXGoiFoCTCYQgWbw+2GTGhEiMdwLdbbd zPUUBByI7y6B6phrt0jXwU4RNses/Eewo8tMLowxNwEI0fohJ3KdryEXd9SNgRo20HO0 4xvUXQ3PBi2JD1F1FL7vx6pmra6Gz96fMUNfW3iZxVnGCeF8JDwkqgnRrY/DfjuShUKh Ih/2sewGmL+hwvW++iK/tmSKcOWiXM1Up2j8uwMSgOayCO4tElN47rNOEUjfnTurSf+e j4Tw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=FYaDQz3WXMafrdPOH+jBu7t6CM5IN56m+9lLa8Z9mro=; b=cWD8M/x3XqZ6/aU/NnGWTM6jozM2zEphKOYc4xMcDkFXc96UlEw/3LNdKoy5Qfd3yO 4te1bD39nvGP3ZoK/of9XZqRF+StbHBq4jQaDvHTOLR2s5DzzdtAstvwR0sAbEd4JII9 fU/+1awQzybSJErLOpzKzMWxwrNBXwyJLIH5r/HpVAKTD7CXB9O0zuMDag2C1yNXd7J4 V87HhLkHIfdBlDGIo/t/vxK+LiRlvB38rArvXZMVjY5O3SEOwfpfr6o/xdkN/2twAXhh x3NqIDndANtYHvjmyFnWLlELrshEkRzjIQcZzelBfjXw+W7LWvE+0N5phYU+uvm+gqi5 bRxg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b="pZqym/K4"; 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 hs5si19184080ejc.359.2021.08.24.13.07.30; Tue, 24 Aug 2021 13:07:54 -0700 (PDT) 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=@infradead.org header.s=casper.20170209 header.b="pZqym/K4"; 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 S234941AbhHXUC4 (ORCPT + 99 others); Tue, 24 Aug 2021 16:02:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42800 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229514AbhHXUCz (ORCPT ); Tue, 24 Aug 2021 16:02:55 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 24A6DC061757; Tue, 24 Aug 2021 13:02:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=FYaDQz3WXMafrdPOH+jBu7t6CM5IN56m+9lLa8Z9mro=; b=pZqym/K4FkqCcx0j8hZ4dbgx8r /wYknUVZpHFrpweFZlbVDhG7BcOWmVlTwYfFXBHWo+kfG/iOTwZIv8mgTv9knzSmtBGNlK9IiD4xc u7f0XoYNuNxI7XeaxQOwuLRKdCK1tjrNXXOHgJNwWxnxle6byWvVg/48uoDuDtY3wUnmmbTquEjkg caATO6kd0GLHslkSKw9qxhzyIVRLHua2R2jn+j230P6OK2M1ReC+8QMEZttY6a2C04YNp3eEf7bC/ ixDSOzchYz5z72uFxNgd94E2S575z/ipN3hqVD4jfUG93nU7PFaH18JK/MM1BAgTnKouCLzW3pPDQ dpEDnpaA==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1mIcat-00BVIy-UI; Tue, 24 Aug 2021 20:00:48 +0000 Date: Tue, 24 Aug 2021 21:00:23 +0100 From: Matthew Wilcox To: Theodore Ts'o Cc: Linus Torvalds , David Howells , Johannes Weiner , Linux-MM , linux-fsdevel , Linux Kernel Mailing List , Andrew Morton Subject: Re: [GIT PULL] Memory folios for v5.15 Message-ID: References: <1957060.1629820467@warthog.procyon.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Aug 24, 2021 at 03:44:48PM -0400, Theodore Ts'o wrote: > On Tue, Aug 24, 2021 at 08:23:15PM +0100, Matthew Wilcox wrote: > > > So when you mention "slab" as a name example, that's not the argument > > > you think it is. That's a real honest-to-goodness operating system > > > convention name that doesn't exactly predate Linux, but is most > > > certainly not new. > > > > Sure, but at the time Jeff Bonwick chose it, it had no meaning in > > computer science or operating system design. > > I think the big difference is that "slab" is mostly used as an > internal name. In Linux it doesn't even leak out to the users, since > we use kmem_cache_{create,alloc,free,destroy}(). So the "slab" > doesn't even show up in the API. /proc/slabinfo /proc/sys/vm/min_slab_ratio /sys/kernel/slab include/linux/slab.h cpuset.memory_spread_slab failslab= slab_merge slab_max_order= $ git grep slab fs/ext4 |wc -l 30 (13 of which are slab.h) > The problem is whether we use struct head_page, or folio, or mempages, > we're going to be subsystem users' faces. And people who are using it > every day will eventually get used to anything, whether it's "folio" > or "xmoqax", we sould give a thought to newcomers to Linux file system > code. If they see things like "read_folio()", they are going to be > far more confused than "read_pages()" or "read_mempages()". > > Sure, one impenetrable code word isn't that bad. But this is a case > of a death by a thousand cuts. At $WORK, one time we had welcomed an > intern to our group, I had to stop everyone each time that they used > an acronym, or a codeword, and asked them to define the term. > > It was really illuminating what an insider takes for granted, but when > it's one cutsy codeword after another, with three or more such > codewords in a sentence, it's *really* a less-than-great initial > experience for a newcomer. > > So if someone sees "kmem_cache_alloc()", they can probably make a > guess what it means, and it's memorable once they learn it. > Similarly, something like "head_page", or "mempages" is going to a bit > more obvious to a kernel newbie. So if we can make a tiny gesture > towards comprehensibility, it would be good to do so while it's still > easier to change the name. I completely agree that it's good to use something which is not jargon, or is at least widely-understood jargon. And I loathe acronyms (you'll notice I haven't suggested a single one). Folio/ream/quire/sheaf were all attempts to get across "collection of pages". Another direction would be something that is associated with memory (but I don't have a good example). Or a non-English word (roman? seite? sidor?) We're going to end up with hpage, aren't we?