sslutil: try harder to avoid getpeercert problems
We wrap both calls to getpeercert in a try/except to make sure we
catch its bogus AttributeError.
copies._forwardcopies: use set operations to find missing files
This is a performance win for a number of reasons:
- We don't iterate over contexts, which avoids a completely unnecessary sorted
call + the O(number of files) abstraction cost of doing that.
- We don't check membership in a context, which avoids another
O(number of files) abstraction cost.
- We iterate over the manifests in C instead of Python.
For a large repo with 170,000 files, this improves perfpathcopies from 0.34
seconds to 0.07. Anything that uses pathcopies, such as rebase or diff --git
between two revisions, benefits.
perf: add a command to test copies.pathcopies perf
An upcoming patch will improve the performance of this function, and this
command will be used to demonstrate that improvement.
Added signature for changeset
8a7bd2dccd44
Added tag 2.5.4 for changeset
8a7bd2dccd44
applyupdates: assign variable before we try to use it (
issue3855)
The variable 'fd' was getting used with a value left over from a prior
iteration, causing a KeyError: '.hgsubstate'.
perf: add a command to test addremove performance
Upcoming patches will improve addremove performance. This command will be used
to demonstrate that improvement.