Commit Graph

7 Commits

Author SHA1 Message Date
Martijn Pieters
15383f0bd3 sparse: use manifest matcher when discovering profiles
Summary:
This echos the change in D7056650; there is no need to special-case
treemanifests here; delegation to the manifest .match method allows the
manifest to apply optimisations when available.

Differential Revision: D7100363

fbshipit-source-id: 66a35850a132f804efb407712d2e4db737c10cff
2018-04-13 21:51:22 -07:00
Martijn Pieters
3b4b3d8cbb sparse: make use of matchers for faster path listing
Summary:
The current code iterates over all files in the manifest, filtering against a prefix.

But a manifest supports using a matcher directly, and efficient implementations like the treemanifest will prune the tree to a much smaller subset rapidly based on the path in a matcher. Switching to using a matcher dramatically improves --cwd-list performance in fbsource, when treemanifests are available.

Reviewed By: quark-zju

Differential Revision: D7056650

fbshipit-source-id: 2bf62ea93680323a49c9282266118805881d7b02
2018-04-13 21:51:21 -07:00
Martijn Pieters
42ac84e8cf sparse: clean up path handling, making it platform agnostic
Summary:
There is no need to strip path separators from the normalised path; normpath
will never leave any.

We also ensure that the path prefix we test ends in a path separator, to avoid
matching on sibling paths that happen to share a prefix.

Reviewed By: ryanmce

Differential Revision: D7056649

fbshipit-source-id: 10b78a78ba44fbc8d9c05fb7ffd0ffd1c1496a67
2018-04-13 21:51:18 -07:00
Peter Na
0911201aa9 fbsparse: add progress output for refresh
Summary: Adds output to hg sparse --refresh for long running calculations, --verbose adds more notes on progress.

Reviewed By: ryanmce

Differential Revision: D6886545

fbshipit-source-id: 9fe176724bec0cb56bc8da4939f42a6e7745cf41
2018-04-13 21:51:04 -07:00
Phil Cohen
66cb3160e1 sparse: don't materialize sparse files during IMM
There's no need to do this and not doing so speeds up IMM tremendously when the sparse profile had to be adjusted.

(This is the grafted version from the fb-hgext repo)

Test Plan:

I ran an IMM before and after this change. Both succeeded but the later version was
much faster.

Differential Revision: https://phab.mercurial-scm.org/D1805
2018-01-16 17:43:19 -08:00
Kostia Balytskyi
0e4d95b67e fb-hgext: fix gendoc-related issues
Summary:
These fixes are related to documentation-related check-style tests.

Depends on D6675344

Test Plan: - more tests pass

Reviewers: #sourcecontrol

Differential Revision: https://phabricator.intern.facebook.com/D6675351
2018-01-09 03:44:33 -08:00
Kostia Balytskyi
e75b9fc1b1 fb-hgext: move most of hgext3rd and related tests to core
Summary:
This commit moves most of the stuff in hgext3rd and related tests to
hg-crew/hgext and hg-crew/test respectively.

The things that are not moved are the ones which require some more complex
imports.


Depends on D6675309

Test Plan: - tests are failing at this commit, fixes are in the following commits

Reviewers: #sourcecontrol

Differential Revision: https://phabricator.intern.facebook.com/D6675329
2018-01-09 03:03:59 -08:00