D845: perf: remove fallbacks to ancient versions of dirstate.walk()
martinvonz (Martin von Zweigbergk)
phabricator at mercurial-scm.org
Sat Sep 30 02:28:07 EDT 2017
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGb3538c03a804: perf: remove fallbacks to ancient versions of dirstate.walk() (authored by martinvonz, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D845?vs=2165&id=2170
REVISION DETAIL
https://phab.mercurial-scm.org/D845
AFFECTED FILES
contrib/perf.py
CHANGE DETAILS
diff --git a/contrib/perf.py b/contrib/perf.py
--- a/contrib/perf.py
+++ b/contrib/perf.py
@@ -370,15 +370,8 @@
@command('perfwalk', formatteropts)
def perfwalk(ui, repo, *pats, **opts):
timer, fm = gettimer(ui, opts)
- try:
- m = scmutil.match(repo[None], pats, {})
- timer(lambda: len(list(repo.dirstate.walk(m, [], True, False))))
- except Exception:
- try:
- m = scmutil.match(repo[None], pats, {})
- timer(lambda: len([b for a, b, c in repo.dirstate.statwalk([], m)]))
- except Exception:
- timer(lambda: len(list(cmdutil.walk(repo, pats, {}))))
+ m = scmutil.match(repo[None], pats, {})
+ timer(lambda: len(list(repo.dirstate.walk(m, [], True, False))))
fm.end()
@command('perfannotate', formatteropts)
To: martinvonz, #hg-reviewers, quark
Cc: quark, mercurial-devel
More information about the Mercurial-devel
mailing list