Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3897684pxk; Tue, 22 Sep 2020 05:42:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwjZev6oUlOdSxxVyVCGkFGfOrxOn7TeAOAGC1fI05bxM647DMhc61viib0CEU7o+5cNM6u X-Received: by 2002:a17:906:270f:: with SMTP id z15mr4635140ejc.6.1600778548420; Tue, 22 Sep 2020 05:42:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600778548; cv=none; d=google.com; s=arc-20160816; b=gpdaAtIlZCMlKv6N1L0Af9AFK6m2QN5teCs6MYsuit0dR+AxhJnfnj63CfcHmTQcH1 EQf/Le5w5g6vMnxc9F84BP/xr0hXgKCro4C7yBJm1pNb3/7Z53FJqg1EHenDuHviocbI vb1wAbbIi8L5CvdnTsKWhpbhLwRRgu98/V+/trcf4sqILCwCCrIr0Xiqm7oUIdKqorp6 ExPSBA7drIbUY56AAJKmEZmB4NiK02WLb8Qypmo3jrHbkWmFZ74L8tjIYpApR4JoSCBj faw2LovnG9ltGMvzgSeiyOlcMEXVZS9vPZk1Txpm8/ZajMXEakVk4rUYWVGu7w3elFJ+ I8iw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent:references:message-id :in-reply-to:subject:cc:to:from:date:dkim-signature; bh=13v2utUwRQqeWPATCUhCzFKLpxpP9eoRFAS7+tLKUYQ=; b=zF4eMJAuADQbnvGCPMb/1TTFfCWM3pr3osIHuLTYETDNUWDJYjG+nosdJP7hDVSHUY Bj9Q/6P+VveA5xwDkK8pcbhuH1oYjpPFPSCfVz75/q6eMKF7zo5KY9N1GuUkTvPnBZ2X Gy+7twduOq/nQFicLLmeyww8jhS460BTLBoayRY8b3BJxVcFhAOgFYd9Qy1zVS6pgfJC vCu9GzZGym+xVDUUnrq9IiG8bk3su6S9hUb/SLAZ6fUk1o4Cep+SWrnno+OFoe11uq6l lPFH0xPguDJBwqKbMvvrtDzRPkVOEtAC38B90IuRDZ5wW6DcpvUvaDqQb70mWQA0HypT mDRQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=AgDceEZ1; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y19si10060028ejf.251.2020.09.22.05.42.04; Tue, 22 Sep 2020 05:42:28 -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=@redhat.com header.s=mimecast20190719 header.b=AgDceEZ1; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726691AbgIVMjW (ORCPT + 99 others); Tue, 22 Sep 2020 08:39:22 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:38884 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726505AbgIVMjV (ORCPT ); Tue, 22 Sep 2020 08:39:21 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1600778360; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=13v2utUwRQqeWPATCUhCzFKLpxpP9eoRFAS7+tLKUYQ=; b=AgDceEZ1PTwn/7/QRK5b/NIoEERFo4wqyRrrB73r362Qoqr9XbxN8oBaOyn9AhwL4+I/lz BKGkWx7pEi8KA48o+/HgrQMGhi7/+GGbWG3LcdUNiYXYoDQPqXNlt3cdMeBST3HUCTqcsn wIu7XC45H5LUVc1q/1pTdS4uTZ6uOTY= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-411-OH8YTdnSN-C8yKRcopmK_A-1; Tue, 22 Sep 2020 08:39:16 -0400 X-MC-Unique: OH8YTdnSN-C8yKRcopmK_A-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id BBCBD186DD28; Tue, 22 Sep 2020 12:39:13 +0000 (UTC) Received: from file01.intranet.prod.int.rdu2.redhat.com (file01.intranet.prod.int.rdu2.redhat.com [10.11.5.7]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 687CE5C1A3; Tue, 22 Sep 2020 12:39:13 +0000 (UTC) Received: from file01.intranet.prod.int.rdu2.redhat.com (localhost [127.0.0.1]) by file01.intranet.prod.int.rdu2.redhat.com (8.14.4/8.14.4) with ESMTP id 08MCdCgb021345; Tue, 22 Sep 2020 08:39:12 -0400 Received: from localhost (mpatocka@localhost) by file01.intranet.prod.int.rdu2.redhat.com (8.14.4/8.14.4/Submit) with ESMTP id 08MCdBHN021341; Tue, 22 Sep 2020 08:39:12 -0400 X-Authentication-Warning: file01.intranet.prod.int.rdu2.redhat.com: mpatocka owned process doing -bs Date: Tue, 22 Sep 2020 08:39:11 -0400 (EDT) From: Mikulas Patocka X-X-Sender: mpatocka@file01.intranet.prod.int.rdu2.redhat.com To: Matthew Wilcox cc: Dan Williams , Linus Torvalds , Alexander Viro , Andrew Morton , Vishal Verma , Dave Jiang , Ira Weiny , Jan Kara , Eric Sandeen , Dave Chinner , "Kani, Toshi" , "Norton, Scott J" , "Tadakamadla, Rajesh (DCIG/CDI/HPS Perf)" , Linux Kernel Mailing List , linux-fsdevel , linux-nvdimm Subject: Re: NVFS XFS metadata (was: [PATCH] pmem: export the symbols __copy_user_flushcache and __copy_from_user_flushcache) In-Reply-To: <20200922122819.GD32101@casper.infradead.org> Message-ID: References: <20200922122819.GD32101@casper.infradead.org> User-Agent: Alpine 2.02 (LRH 1266 2009-07-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 22 Sep 2020, Matthew Wilcox wrote: > On Mon, Sep 21, 2020 at 12:20:42PM -0400, Mikulas Patocka wrote: > > The same for directories - NVFS hashes the file name and uses radix-tree > > to locate a directory page where the directory entry is located. XFS > > b+trees would result in much more accesses than the radix-tree. > > What? Radix trees behave _horribly_ badly when indexed by a hash. > If you have a 64-bit hash and use 8 bits per level of the tree, you have > to traverse 8 pointers to get to your destination. You might as well > use a linked list! In NVFS, radix trees are cut off - they have only as much internal levels, as is needed to disambiguate the directory entries. Read this document: http://people.redhat.com/~mpatocka/nvfs/INTERNALS the section "DIRECTORIES". Perhaps, I should call it differently than "radix-trees", but I don't really know what is the official name for this data structure. Mikulas