[PATCH 3 of 3] manifest: postpone calling array.array() until needed
mpm at selenic.com
Fri Feb 27 17:56:57 CST 2015
On Thu, 2015-02-26 at 16:02 -0800, Martin von Zweigbergk wrote:
> # HG changeset patch
> # User Martin von Zweigbergk <martinvonz at google.com>
> # Date 1424802971 28800
> # Tue Feb 24 10:36:11 2015 -0800
> # Node ID 1d3fe60a20d4f6284bc295af27f9f272af30dcdd
> # Parent ef7dde10dc5941491a19dbd17ccb47a776f0dadd
> manifest: postpone calling array.array() until needed
> We currently convert a string to an array in manifest.read(), only to
> store the result in the manifest cache. In most cases, the array will
> not be used, so let's store the original string instead. Storage cost
> should be similar assuming strings are stored in memory as byte
> arrays. The only disadvantage should be that the conversion can be
> done several times if multiple new revisions are created based on the
> same cached revision.
I've dropped this one because it looks like it de-optimized back-to-back
commits, for instance of the sort done by pushing a stack of mq patches.
Mathematics is the supreme nostalgia of our time.
More information about the Mercurial-devel