[PATCH 1 of 6] revlog: in _getcandidaterevs, shorten revlog._generaldelta to gdelta

Gregory Szorc gregory.szorc at gmail.com
Wed May 23 21:04:48 EDT 2018


On Tue, May 22, 2018 at 1:08 AM, Paul Morelle <paul.morelle at octobus.net>
wrote:

>
> On 22/05/18 01:12, Gregory Szorc wrote:
>
> On Mon, May 21, 2018 at 2:47 PM, Paul Morelle <paul.morelle at octobus.net>
> wrote:
>
>> # HG changeset patch
>> # User Paul Morelle <paul.morelle at octobus.net>
>> # Date 1525438855 -7200
>> #      Fri May 04 15:00:55 2018 +0200
>> # Node ID 054469518b3480201e7f8ada16957027009e9f64
>> # Parent  514605777244de61b68c7e1503c4f106773913f4
>> # EXP-Topic semi-snapshots
>> # Available At https://bitbucket.org/octobus/mercurial-devel/
>> #              hg pull https://bitbucket.org/octobus/mercurial-devel/ -r
>> 054469518b34
>> revlog: in _getcandidaterevs, shorten revlog._generaldelta to gdelta
>>
>
> Queued parts 1-4. Thanks.
>
> Part 5 failed to apply cleanly. Could you please rebase and resend?
>
> Sure!
>
> However, I am not certain that I have done this properly, as [PATCH 5 of
> 6] and [PATCH 6 of 6] were sent as [PATCH 1 of 2 V2] and [PATCH 2 of 2 V2].
> Is it correct even if the numbers don't match?
>

Yes, it's fine if the patch numbers don't match. It can confuse our review
tools slightly. But that's not your problem.

FWIW Phabricator generally handles partially landed series better than
email, since it tracks series more loosely than the email tools do.


>
>
>
>>
>> diff -r 514605777244 -r 054469518b34 mercurial/revlog.py
>> --- a/mercurial/revlog.py       Fri May 11 23:28:02 2018 -0700
>> +++ b/mercurial/revlog.py       Fri May 04 15:00:55 2018 +0200
>> @@ -305,6 +305,7 @@
>>          grouped by level of easiness.
>>          """
>>          revlog = self.revlog
>> +        gdelta = revlog._generaldelta
>>          curr = len(revlog)
>>          prev = curr - 1
>>          p1r, p2r = revlog.rev(p1), revlog.rev(p2)
>> @@ -316,13 +317,13 @@
>>              # changegroup data into a generaldelta repo. The only time it
>>              # isn't true is if this is the first revision in a delta
>> chain
>>              # or if ``format.generaldelta=true`` disabled
>> ``lazydeltabase``.
>> -            if cachedelta and revlog._generaldelta and
>> revlog._lazydeltabase:
>> +            if cachedelta and gdelta and revlog._lazydeltabase:
>>                  # Assume what we received from the server is a good
>> choice
>>                  # build delta will reuse the cache
>>                  yield (cachedelta[0],)
>>                  tested.add(cachedelta[0])
>>
>> -            if revlog._generaldelta:
>> +            if gdelta:
>>                  # exclude already lazy tested base if any
>>                  parents = [p for p in (p1r, p2r)
>>                             if p != nullrev and p not in tested]
>> _______________________________________________
>> Mercurial-devel mailing list
>> Mercurial-devel at mercurial-scm.org
>> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
>>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mercurial-scm.org/pipermail/mercurial-devel/attachments/20180523/01014552/attachment.html>


More information about the Mercurial-devel mailing list