perf: run 'setup' function during stub run
The benchmarked function might need the content of the setup to be run in order
to function properly.
perf: fallback to subset if ondisk cache is missing in perfbranchmapload
If there is no branchmap on disk for that filter, it means that the cache from
some subset's filter is relevant for this one. We look for it instead of
aborting.
That way it is much simpler to run the command in an automated way. We can now
add it to `test-contrib-perf.t`.
perf: prewarm the branchmap in perfbranchmapload
It is not very interesting to have the command randomly failing because the
branchmap for the tested filter happens to be cold. So we make sure to have a
valid up to date branchmap before going further.
The data might still be missing from disk if a subset was equivalent. See next
changeset for details and fix.
localrepo: correct docstring of filectx()
The same reason as
b6c2543e1dd8. It can't be any changeset specifiers but
revision number.
annotate: remove dead code to not convert path to relative path
It's annotate. There should be at least one file path specified.
annotate: start pager soon after command options are validated
It helps extracting helper class.
annotate: check and update command options first
It helps extracting helper class.
annotate: format local tables in less-dense form
I'll move these to a class, where one-extra indent will be needed.
perf: rename version flag of perfchangegroupchangelog to cgversion
The version flag conflicts with the global version flag and does not work.
Differential Revision: https://phab.mercurial-scm.org/D5297
Differential Revision: https://phab.mercurial-scm.org/D5298
procutil: don't allow the main 'hg' script to be treated as the Windows exe
Previously, there were a handful of errors like this:
$ hg prefetch --repack
(running background incremental repack)
+ abort: %1 is not a valid Win32 application
+ [255]
CreateProcess() doesn't append .exe when `lpApplicationName` contains a path,
and a python script isn't directly executable.