Commit Graph

20 Commits

Author SHA1 Message Date
Brodie Rao
43ab01245b revlog: allow tuning of the chunk cache size (via format.chunkcachesize)
Running perfmoonwalk on the Mercurial repo (with almost 20,000 changesets) on
Mac OS X with an SSD, before this change:

$ hg --config format.chunkcachesize=1024 perfmoonwalk
! wall 2.022021 comb 2.030000 user 1.970000 sys 0.060000 (best of 5)

(16,154 cache hits, 3,840 misses.)

$ hg --config format.chunkcachesize=4096 perfmoonwalk
! wall 1.901006 comb 1.900000 user 1.880000 sys 0.020000 (best of 6)

(19,003 hits, 991 misses.)

$ hg --config format.chunkcachesize=16384 perfmoonwalk
! wall 1.802775 comb 1.800000 user 1.800000 sys 0.000000 (best of 6)

(19,746 hits, 248 misses.)

$ hg --config format.chunkcachesize=32768 perfmoonwalk
! wall 1.818545 comb 1.810000 user 1.810000 sys 0.000000 (best of 6)

(19,870 hits, 124 misses.)

$ hg --config format.chunkcachesize=65536 perfmoonwalk
! wall 1.801350 comb 1.810000 user 1.800000 sys 0.010000 (best of 6)

(19,932 hits, 62 misses.)

$ hg --config format.chunkcachesize=131072 perfmoonwalk
! wall 1.805879 comb 1.820000 user 1.810000 sys 0.010000 (best of 6)

(19,963 hits, 31 misses.)

We may want to change the default size in the future based on testing and
user feedback.
2013-11-17 18:04:29 -05:00
Mads Kiilerich
26b3c84619 localrepo: store requirements sorted 2012-12-12 02:38:14 +01:00
Mads Kiilerich
915c0dcd46 tests: use hghave eol-in-paths to test for support for ':' in filenames and " "
It is an approximation but seems to work ok ... and testing that 'foo:bar'
creates a real file and not just a resource fork is not completely trivial.
2012-06-15 00:02:27 +02:00
Adrian Buehlmann
30989f3fa5 test-init: enable for Windows
On Windows, we can't create a directory with the name " ", as that is
not a valid name for a directory.
2012-06-11 13:41:02 +02:00
Mads Kiilerich
8564a7de60 tests: quote dummyssh in a way that works on windows too
Don't depend on $environmentvariableexpansion and 'quote' handling in system()
2012-04-28 02:00:04 +02:00
Thomas Arendsen Hein
21bb7c4cdc tests: make tests work if directory contains special characters
With this quoting tests will work e.g. in "/tmp/foo bar/mercurial/".
2012-04-03 19:06:35 +02:00
Mads Kiilerich
2ee0e99705 sshrepo: don't quote obviously safe strings (issue2983)
This restores compatibility with hg-over-ssh servers that don't parse
commandlines as sh does but works ok in the most common cases.
2011-12-08 16:39:00 +01:00
Mads Kiilerich
c4feda7dd3 ssh: quote remote paths (issue2983) 2011-11-26 00:10:31 +01:00
Mads Kiilerich
8344ac235d tests: use 'hghave no-windows' to avoid testing reserved file names on windows 2011-11-07 03:14:55 +01:00
Andrew Pritchard
99a944ad65 localrepo: make requirements attribute of newly-created repos contain a set
This is for internal consistency, as this attribute typically contains a set
2011-07-20 18:23:06 -04:00
Mads Kiilerich
adf83aa0ff tests: share dummyssh 2011-05-05 01:47:46 +02:00
David Soria Parra
d5ce5f0e0b hg: add support for cloning bookmarks 2011-03-13 12:24:17 +01:00
Adrian Buehlmann
68a7a3545a tests: add testcase for --config format.dotencode=false 2010-10-11 11:17:48 +02:00
Adrian Buehlmann
04f7530508 store: encode first period or space in filenames (issue1713)
- Mac OS X has problems with filenames starting with '._'
  (e.g. '.FOO' -> '._f_o_o' is now encoded as '~2e_f_o_o')

- Explorer of Windows Vista and Windows 7 strip leading spaces of
  path elements of filenames when copying trees

Above problems are avoided by encoding the first space (as '~20') or
period (as '~2e') of all path elements.

This introduces a new entry 'dotencode' in .hg/requires, that is,
a new repository filename layout (inside .hg/store).

Newly created repositories require 'dotencode' by default. Specifying

  [format]
  dotencode = False

in a config file will use the old format instead.

Prior Mercurial versions will abort with the message

   abort: requirement 'dotencode' not supported!

when trying to access a local repository that requires 'dotencode'.

New 'dotencode' repositories can be converted to the previous
repository format with

  hg --config format.dotencode=0 clone --pull repoA repoB
2010-10-09 21:54:50 +02:00
Mads Kiilerich
11c8cc29c9 init: expand destination url as a configured paths
Most commands expands configured paths when repositories are specified, just as
the urls help says. Clone also expands the destination path. Clone is morally
equivalent to init + push/pull, so init should also expand the destination path
- and that is what this patch makes it do.

There is no really good usecases for this and in most cases it doesn't matter,
but consistency is nice, and otherwise we would have to document the exception.
2010-09-29 01:32:51 +02:00
Matt Mackall
200e89394d tests: fix a bunch of pointless #s in unified tests 2010-09-17 17:03:08 -05:00
Matt Mackall
08439e0f2d tests: add exit codes to unified tests 2010-09-16 17:51:32 -05:00
Martin Geisler
cc612c476f tests: remove unneeded -d flags
Many tests fixed the commit date of their changesets at '1000000 0' or
similar. However testing with "Mon Jan 12 13:46:40 1970 +0000" is not
better than testing with "Thu Jan 01 00:00:00 1970 +0000", which is
the default run-tests.py installs.

Removing the unnecessary flag removes some clutter and will hopefully
make it clearer what the tests are really trying to test. Some tests
did not even change their output when the dates were changed, in which
case the -d flag was truly irrelevant.

Dates used in sequence (such as '0 0', '1 0', etc...) were left alone
since they may make the test easier to understand.
2010-09-02 23:22:51 +02:00
Martin Geisler
699ed71d72 test-init: replace 'echo -n' with 'printf'
The '-n' argument to echo is a non-standard extension that isn't
supported on Mac OS X 10.6.
2010-08-15 17:42:44 +02:00
Nicolas Dumazet
56a88af68c tests: unify test-init 2010-08-12 15:31:18 +09:00