Fri, 21 Mar 2014 16:09:17 -0700 subrepo: factor out Git version check to add doctests
Siddharth Agarwal <sid0@fb.com> [Fri, 21 Mar 2014 16:09:17 -0700] rev 20840
subrepo: factor out Git version check to add doctests Followup to 6a2acb0d9352::e5641536e4d5.
Sat, 15 Feb 2014 19:51:20 +0900 contrib: add "hgperf" command to measure performance of commands easily
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sat, 15 Feb 2014 19:51:20 +0900] rev 20839
contrib: add "hgperf" command to measure performance of commands easily Newly added "hgperf" command repeats "dispatch.runcommand()" for specified Mercurial command and measure performance of it in the same manner of "contrib/perf.py" extension. Users (mainly developers) can examine performance of the target command easily, without adding new entry for it to "contrib/perf.py" extension.
Sat, 15 Feb 2014 19:54:14 +0900 grep: exit loop immediately, if matching is found in the file for "hg grep -l"
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sat, 15 Feb 2014 19:54:14 +0900] rev 20838
grep: exit loop immediately, if matching is found in the file for "hg grep -l" Before this patch, internal function "display()" of "hg grep" is not efficient for "-l"/"--files-with-matches", because loop is continued, even after the first matching is found in the specified file. This patch exits loop immediately, if matching is found for "--files-with-matches". In this case, "before is None" is equal to "opts.get('files_with_matches')".
Sat, 15 Feb 2014 19:54:05 +0900 grep: use "found" instead of "filerevmatches" examination for efficiency
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sat, 15 Feb 2014 19:54:05 +0900] rev 20837
grep: use "found" instead of "filerevmatches" examination for efficiency Before this patch, internal function "display()" of "hg grep" stores whether matching is already found or not into the dictionary "filerevmatches" by "(fn, rev)" tuple as the key. But this is redundant, because: - "filerevmatches" is local variable of "display()", so each "display()" invocations don't affect others - both "fn" and "rev" (gotten from "ctx" argument) are never changed in each "display()" invocations Then, "filerevmatches" should have only one entry at most, and "(fn, rev) in filerevmatches" should be equal to "found". This patch uses "found" instead of "filerevmatches" examination for efficiency.
Sat, 15 Feb 2014 19:52:36 +0900 grep: reuse the first "util.binary()" result for efficiency
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sat, 15 Feb 2014 19:52:36 +0900] rev 20836
grep: reuse the first "util.binary()" result for efficiency Before this patch, to check whether the file in the specified revision is binary or not, "util.binary()" is invoked via internal function "binary()" of "hg grep" once per a line of "hg grep" output, even though binary-ness is not changed in the same file. This patch reuses the first "util.binary()" invocation result by annotating internal function "binary()" with "@util.cachefunc". Performance improvement measured by "hgperf grep -r 88d8e568add1 vfs mercurial/scmutil.py": before this patch: ! wall 0.024000 comb 0.015600 user 0.015600 sys 0.000000 (best of 118) after this patch: ! wall 0.023000 comb 0.015600 user 0.015600 sys 0.000000 (best of 123) Status of recent(88d8e568add1) "mercurial/scmutil.py": # of lines: 919 (may affect cost of search) # of bytes: 29633 (may affect cost of "util.binary()") # of matches: 22 (may affect frequency of "util.binary()")
Sat, 15 Feb 2014 19:52:26 +0900 util: add the code path to "cachefunc()" for the function taking no arguments
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sat, 15 Feb 2014 19:52:26 +0900] rev 20835
util: add the code path to "cachefunc()" for the function taking no arguments Before this patch, "util.cachefunc()" caches the value returned by the specified function into dictionary "cache", even if the specified function takes no arguments. In such case, "cache" has at most one entry, and distinction between entries in "cache" is meaningless. This patch adds the code path to "cachefunc()" for the function taking no arguments for efficiency: to store only one cached value, using list "cache" is a little faster than using dictionary "cache".
Wed, 26 Mar 2014 12:52:57 -0500 help: add examples to incoming
Matt Mackall <mpm@selenic.com> [Wed, 26 Mar 2014 12:52:57 -0500] rev 20834
help: add examples to incoming
Tue, 25 Mar 2014 16:10:07 -0700 revset: fix generatorset race condition
Durham Goode <durham@fb.com> [Tue, 25 Mar 2014 16:10:07 -0700] rev 20833
revset: fix generatorset race condition If two things were iterating over a generatorset at the same time, they could miss out on the things the other was generating, resulting in incomplete results. This fixes it by making it possible for two things to iterate at once, by always checking the _genlist at the beginning of each iteration. I was only able to repro it with pending changes from my other commits, but they aren't ready yet. So I'm unable to add a test for now.
Tue, 25 Mar 2014 23:07:52 +0100 tests: don't hardcode path to bash interpreter
Olle Lundberg <geek@nerd.sh> [Tue, 25 Mar 2014 23:07:52 +0100] rev 20832
tests: don't hardcode path to bash interpreter Use the env binary to figure out the correct bash to use. Certain systems ships with an ancient version of bash, but the user might have installed a newer one that is earlier in $PATH. For example the current version of Mac OS X ships version 3.2.51 of bash, which does not understand new fancy builtins such as readarray. A user might install a newer version of bash, use that as their shell and add that path before bin.
Wed, 26 Mar 2014 11:59:13 +0100 contrib: don't hardcode path to bash interpreter
Olle Lundberg <geek@nerd.sh> [Wed, 26 Mar 2014 11:59:13 +0100] rev 20831
contrib: don't hardcode path to bash interpreter Use the env binary to figure out the correct bash to use. Certain systems ships with an ancient version of bash, but the user might have installed a newer one that is earlier in $PATH. For example the current version of Mac OS X ships version 3.2.51 of bash, which does not understand new fancy builtins such as readarray. A user might install a newer version of bash, use that as their shell and add that path before bin.
(0) -10000 -3000 -1000 -300 -100 -10 +10 +100 +300 +1000 +3000 +10000 +30000 tip