From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS53758 23.128.96.0/24 X-Spam-Status: No, score=-3.9 required=3.0 tests=AWL,BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by dcvr.yhbt.net (Postfix) with ESMTP id 30EA81FA12 for ; Wed, 21 Jul 2021 11:37:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238323AbhGUKon (ORCPT ); Wed, 21 Jul 2021 06:44:43 -0400 Received: from cloud.peff.net ([104.130.231.41]:53022 "EHLO cloud.peff.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237528AbhGUJii (ORCPT ); Wed, 21 Jul 2021 05:38:38 -0400 Received: (qmail 1997 invoked by uid 109); 21 Jul 2021 10:18:28 -0000 Received: from Unknown (HELO peff.net) (10.0.1.2) by cloud.peff.net (qpsmtpd/0.94) with ESMTP; Wed, 21 Jul 2021 10:18:28 +0000 Authentication-Results: cloud.peff.net; auth=none Received: (qmail 2920 invoked by uid 111); 21 Jul 2021 10:18:48 -0000 Received: from coredump.intra.peff.net (HELO sigill.intra.peff.net) (10.0.0.2) by peff.net (qpsmtpd/0.94) with (TLS_AES_256_GCM_SHA384 encrypted) ESMTPS; Wed, 21 Jul 2021 06:18:48 -0400 Authentication-Results: peff.net; auth=none Date: Wed, 21 Jul 2021 06:18:46 -0400 From: Jeff King To: Taylor Blau Cc: git@vger.kernel.org, dstolee@microsoft.com, gitster@pobox.com, jonathantanmy@google.com Subject: Re: [PATCH v2 05/24] Documentation: describe MIDX-based bitmaps Message-ID: References: <64a260e0c6a116b7c6fa6fea2b9fd96bf416cb18.1624314293.git.me@ttaylorr.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <64a260e0c6a116b7c6fa6fea2b9fd96bf416cb18.1624314293.git.me@ttaylorr.com> Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org On Mon, Jun 21, 2021 at 06:25:10PM -0400, Taylor Blau wrote: > +An object is uniquely described by its bit position within a bitmap: > + > + - If the bitmap belongs to a packfile, the __n__th bit corresponds to > + the __n__th object in pack order. For a function `offset` which maps > + objects to their byte offset within a pack, pack order is defined as > + follows: > + > + o1 <= o2 <==> offset(o1) <= offset(o2) > + > + - If the bitmap belongs to a MIDX, the __n__th bit corresponds to the > + __n__th object in MIDX order. With an additional function `pack` which > + maps objects to the pack they were selected from by the MIDX, MIDX order > + is defined as follows: > + > + o1 <= o2 <==> pack(o1) <= pack(o2) /\ offset(o1) <= offset(o2) > + > + The ordering between packs is done lexicographically by the pack name, > + with the exception of the preferred pack, which sorts ahead of all other > + packs. This doesn't render well as asciidoc (the final paragraph is taken as more of the code block). But that is a problem through the whole file. I think we should ignore it for now, and worry about asciidoc-ifying the whole thing later, if we choose to. > + The ordering between packs is done lexicographically by the pack name, > + with the exception of the preferred pack, which sorts ahead of all other > + packs. Hmm, I'm not sure if this "lexicographically" part is true. Really we're building on the midx .rev format here. And that says "defined by the MIDX's pack list" (though I can't offhand remember if that is lexicographic, or if it is in the reverse-mtime order). At any rate, should we just be referencing the rev documentation? > [...] The rest of the changes to the document seemed quite sensible to me. -Peff