[PATCH 2 of 4 V2] parsers: write dirstate starting with non-normal entries

Martin von Zweigbergk martinvonz at google.com
Mon Nov 30 23:33:21 CST 2015


On Mon, Nov 30, 2015 at 4:57 PM Laurent Charignon <lcharignon at fb.com> wrote:

> # HG changeset patch
> # User Laurent Charignon <lcharignon at fb.com>
> # Date 1448930384 28800
> #      Mon Nov 30 16:39:44 2015 -0800
> # Node ID 5e659a9b2694d155e33286ef9b236e092ce80ad0
> # Parent  a86356722e51056c2bbfd6accae954ca386d92e1
> parsers: write dirstate starting with non-normal entries
>
> Before this patch we were writing the dirstate entries in a "random" way,
> following the *unstable* order of a Python dictionary. This patch changes
> the
> order in which we write the dirstate entries.
>
> We now start with the non-normal files (that have changed and likely to
> have
> changed) and end with the normal files. This makes the job of hg status
> easier
> as, in most cases, it will need to access the non-normal entries of the
> dirstate. This new ordering allows hg status to stop iterating over the
> dirstate
> after processing those entries.
>

But that change to "hg status" is not in this patch, correct? Is it coming
later? It seems like some way of indicating whether the dirstate was
written in this order is needed so the reader knows whether it has to read
all of it or not. Maybe that's also coming later, or maybe you will just
depend on that fact internally where you can better control what version of
hg people are running? It feels like I'm missing some context here that
others may have. Sorry if these are silly questions.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20151201/9d7e7af1/attachment.html>


More information about the Mercurial-devel mailing list