Received: by 10.223.164.202 with SMTP id h10csp2610250wrb; Fri, 24 Nov 2017 14:03:40 -0800 (PST) X-Google-Smtp-Source: AGs4zMYJ+bh3Wx+xupDtAZ0yQeecC+Jx9fuowA0Csrm7D9vtlBvE6OPNPeRMKhgK2oemmguuKgF2 X-Received: by 10.84.217.2 with SMTP id o2mr30215980pli.338.1511561020608; Fri, 24 Nov 2017 14:03:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1511561020; cv=none; d=google.com; s=arc-20160816; b=MWSv0V3CE7x3JpAaHT2ib8ZC9m6iKybRxG7KVchwVNk2gT8uiKssGqLk8kIg359wtm SH6/etZurltS3J8piHeqo/mWgXNYaYS0JCB0qeXB4Rb8FgtwQmIxjiHof9ubxWD9Tu8y Nlmh3NqmY1dP6bF2/9uhgvzc/FnHKI2xmouQXbhdvyTh+XZ+bFZkhSOc3FBMO1A5Yax4 P5KKDKqKDzl7mTefiZzGBOeMDZBdMmT6pIcHRPQD6MfcP8gSMmj6nOuBIHjDkd8rsmST E9UTPCSZ/sbxi0N3oBU7q1m4Ei3rk9r92lc9o1/6NoeaPnZT9UAQubM1VqyVcRnHDqTW RCSg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=1pL5acgm6P8eDJENZla/D8sRoCsY1vqnxXQcQcx2OBY=; b=fCA1ZlAr1H0//GIIUo212Ey4Xy2+Eljj2G5ILqLXOxxxmssbYnqe1t+u7wF0jemU7d 1yxFi1IzE9oQqj8Qn2MwBBB7HTprsnZ/PgN7fvgEct48b2zedHrCWuXze2ghrHsmA1V3 jtIKvUHMqGnpGUFJr8CwF/O5Vnju30Nwdco+aM4S++FqzY7Wn3hcGvYreCQ84DRy/51T s1zX6+jisEiqXzAizljm6TnQ16wT6d+gKVVMYtzbQ7Hg3Doh8uOSLXn9qHKyG8F4FWOU shbOLZ9HLRQpm4nbp1CI6tg+tfBdV99TT4/4u2RJ+udhm9JUE4fnf1r2FBUGRQqfGbGi v+Kg== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k8si18539276pgt.29.2017.11.24.14.03.25; Fri, 24 Nov 2017 14:03:40 -0800 (PST) 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753862AbdKXWCo convert rfc822-to-8bit (ORCPT + 78 others); Fri, 24 Nov 2017 17:02:44 -0500 Received: from mondschein.lichtvoll.de ([194.150.191.11]:52819 "EHLO mail.lichtvoll.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753730AbdKXWCn (ORCPT ); Fri, 24 Nov 2017 17:02:43 -0500 Received: from merkaba.localnet (ppp-46-244-249-83.dynamic.mnet-online.de [46.244.249.83]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.lichtvoll.de (Postfix) with ESMTPSA id 1374A1EE953; Fri, 24 Nov 2017 23:02:42 +0100 (CET) From: Martin Steigerwald To: Matthew Wilcox Cc: linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Matthew Wilcox Subject: Re: XArray documentation Date: Fri, 24 Nov 2017 23:02:41 +0100 Message-ID: <7001154.REmHhS1LlQ@merkaba> In-Reply-To: <20171124211809.GA17136@bombadil.infradead.org> References: <20171122210739.29916-1-willy@infradead.org> <2627399.jpLCoM7KBo@merkaba> <20171124211809.GA17136@bombadil.infradead.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8BIT Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Matthew Wilcox - 24.11.17, 22:18: > On Fri, Nov 24, 2017 at 07:01:31PM +0100, Martin Steigerwald wrote: > > > The XArray is an abstract data type which behaves like an infinitely > > > large array of pointers. The index into the array is an unsigned long. > > > A freshly-initialised XArray contains a NULL pointer at every index. > > > > Yes, I think this is clearer already. > > > > Maybe with a few sentences on "Why does the kernel provide this?", "Where > > is it used?" (if already known), "What use case is it suitable for – if I > > want to implement something into the kernel (or in user space?) ?" and > > probably "How does it differ from user data structures the kernel > > provides?" > > OK, I think this is getting more useful. Here's what I currently have: > > Overview > ======== > > The XArray is an abstract data type which behaves like a very large array > of pointers. It meets many of the same needs as a hash or a conventional > resizable array. Unlike a hash, it allows you to sensibly go to the > next or previous entry in a cache-efficient manner. In contrast to > a resizable array, there is no need for copying data or changing MMU > mappings in order to grow the array. It is more memory-efficient, > parallelisable and cache friendly than a doubly-linked list. It takes > advantage of RCU to perform lookups without locking. I like this. I bet I may not be able help much further with it other than to possibly proofread it tomorrow. Thank you for considering my suggestion. -- Martin From 1584983844149574802@xxx Fri Nov 24 21:19:44 +0000 2017 X-GM-THRID: 1584908277167360414 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread