Mercurial > hg
view tests/test-merge9.t @ 46095:93e09d370003
treemanifest: stop storing full path for each item in manifest._lazydirs
This information is obtainable, if needed, based on the lazydirs key (which is
the entry name) and the manifest's `dir()` method.
### Performance
This is actually both a memory and a performance improvement, but it's likely to
be a very small one in most situations. In the pathological repo I've been using
for testing other performance work I've done recently, this reduced the time for
a rebase operation (rebasing two commits across a public-phase change that
touches a sibling of one of my tracked directories where the common parent is
massive (>>10k entries)):
#### Before
```
Time (mean ± σ): 4.059 s ± 0.121 s [User: 0.9 ms, System: 0.6 ms]
Range (min … max): 3.941 s … 4.352 s 10 runs
```
#### After
```
Time (mean ± σ): 3.707 s ± 0.060 s [User: 0.8 ms, System: 0.8 ms]
Range (min … max): 3.648 s … 3.818 s 10 runs
```
Differential Revision: https://phab.mercurial-scm.org/D9553
author | Kyle Lippincott <spectral@google.com> |
---|---|
date | Thu, 03 Dec 2020 14:39:39 -0800 |
parents | 8d72e29ad1e0 |
children | 38941a28406a |
line wrap: on
line source
test that we don't interrupt the merge session if a file-level merge failed $ hg init repo $ cd repo $ echo foo > foo $ echo a > bar $ hg ci -Am 'add foo' adding bar adding foo $ hg mv foo baz $ echo b >> bar $ echo quux > quux1 $ hg ci -Am 'mv foo baz' adding quux1 $ hg up -qC 0 $ echo >> foo $ echo c >> bar $ echo quux > quux2 $ hg ci -Am 'change foo' adding quux2 created new head test with the rename on the remote side $ HGMERGE=false hg merge merging bar merging foo and baz to baz merging bar failed! 1 files updated, 1 files merged, 0 files removed, 1 files unresolved use 'hg resolve' to retry unresolved file merges or 'hg merge --abort' to abandon [1] $ hg resolve -l U bar R baz test with the rename on the local side $ hg up -C 1 3 files updated, 0 files merged, 1 files removed, 0 files unresolved $ HGMERGE=false hg merge merging bar merging baz and foo to baz merging bar failed! 1 files updated, 1 files merged, 0 files removed, 1 files unresolved use 'hg resolve' to retry unresolved file merges or 'hg merge --abort' to abandon [1] show unresolved $ hg resolve -l U bar R baz unmark baz $ hg resolve -u baz show $ hg resolve -l U bar U baz $ hg st M bar M baz M quux2 ? bar.orig re-resolve baz $ hg resolve baz merging baz and foo to baz after resolve $ hg resolve -l U bar R baz resolve all warning $ hg resolve abort: no files or directories specified (use --all to re-merge all unresolved files) [10] resolve all $ hg resolve -a merging bar warning: conflicts while merging bar! (edit, then use 'hg resolve --mark') [1] after $ hg resolve -l U bar R baz $ cd ..