Commit Graph

17 Commits

Author SHA1 Message Date
Siddharth Agarwal
c97c4cf7f6 merge.mergestate: perform all premerges before any merges (BC)
We perform all that we can non-interactively before prompting the user for input
via their merge tool. This allows for a maximally consistent state when the user
is first prompted.

The test output changes indicate the actual behavior change happening.
2015-10-11 21:56:39 -07:00
Siddharth Agarwal
30c73e4dd2 filemerge: normalize 'internal:foo' names to ':foo'
In upcoming patches we're going to present these names in the UI -- it would be
good not to present deprecated names.
2015-10-07 00:01:16 -07:00
Durham Goode
1bef6fef82 copy: add flag for disabling copy tracing
Copy tracing can be up to 80% of rebase time when rebasing stacks of commits in
large repos (hundreds of thousands of files).  This provides the option of
turning off the majority of copy tracing. It does not turn off _forwardcopies()
since that is used to carry copy information inside a commit across a rebase.

This will affect the situation where a user edits a file, then rebases on top of
commits that have moved that file. The move will not be detected and the user
will have to manually resolve the issue (possibly by redoing the rebase with
this flag off).

The reason to have a flag instead of trying to fix the actual copy tracing
performance is that copy tracing is fundamentally an O(number of files in the
repo) operation.  In order to know if file X in the rebase source was copied
anywhere, we have to walk the filelog for every new file that exists in the
rebase destination (i.e. a file in the destination that is not in the common
ancestor).  Without an index that lets us trace forward (i.e. from file Y in the
common ancestor forward to the rebase destination), it will never be an O(number
of changes in my branch) operation.

In mozilla-central, rebasing a 3 commit stack across 20,000 revs goes from 39s
to 11s.
2015-01-27 11:26:27 -08:00
Pierre-Yves David
281365197e progress: get the extremely verbose output out of default debug
When the progress extension is not enabled, each call to 'ui.progress' used to
issue a debug message. This results is a very verbose output and often redundant
in tests. Dropping it makes tests less volatile to factor they do not meant to
test.

We had to alter the sed trick in 'test-rename-merge2.t'. Sed is used to drop all
output from a certain point and hidding the progress output remove its anchor.
So we anchor on something else.
2015-05-09 23:40:40 -07:00
Mads Kiilerich
473137c772 merge: change debug logging - test output changes but no real changes
Preparing for action list split-up, making sure the final change don't have any
test changes.

The patch moves debug statements around without really changing anything.
Arguably, it temporarily makes the code worse. The only justification is that
it makes it easier to review the test changes ... and in the end the big change
will not change test output at all.

The changes to test output are due to changes in the ordering of debug output.
That is mainly because we now do the debug logging for files when we actually
process them. Files are also processed in a slightly different but still
correct order. It is now primarily ordered by action type, secondarily by
filename.

The patch introduces some redundancy. Some of it will be removed again, some of
it will in the end help code readability and efficiency. It is possible that we
later on could introduce a "process this action list and do some logging and
progress reporting and apply this function".

The "preserving X for resolve" debug statements will only have single space
indentation. It will no longer have a leading single space indented "f: msg ->
m" message. Having this message double indented would thus no longer make
sense.

The bid actions will temporarily be sorted using a custom sort key that happens
to match the sort order the simplified code will have in the end.
2014-04-22 02:10:25 +02:00
Mads Kiilerich
a0f70f6a56 merge: keep destination filename as key in filemerge actions
Gives more readable debug output and makes it possible to compare/merge actions
later.
2014-03-02 18:52:16 +01:00
Siddharth Agarwal
ace5cac25b manifestmerge: pass in branchmerge and force separately
This will be used in an upcoming patch.
2013-02-08 15:23:23 +00:00
Mads Kiilerich
ee476759ff merge: delay debug messages for merge actions
Show messages at a point where the actions have been sorted, thus preparing for
backout of 14f4258e3526.

This makes manifestmerge more of a silent operation, just like 'copies' is.

Indent 'preserving' messages to make them subordinate to the action logging so
they fit in the new context. (The 'preserving' messages are quite redundant and
could also be removed completely.)
2013-01-24 23:57:44 +01:00
Mads Kiilerich
2e43383c70 copies: report found copies sorted 2012-12-12 02:38:14 +01:00
Mads Kiilerich
bc50dd6c71 merge: process files in sorted order 2013-01-15 02:59:12 +01:00
Siddharth Agarwal
76d4a91eed copies: make debug messages more sensible
The -> in debug messages is currently overloaded to mean both source to dest
and dest to source. To fix this, we add explicit labels and make the arrow
direction consistent.
2012-12-26 15:03:58 -08:00
Mads Kiilerich
fa1c4e5ebe tests: add missing trailing 'cd ..'
Many tests didn't change back from subdirectories at the end of the tests ...
and they don't have to. The missing 'cd ..' could always be added when another
test case is added to the test file.

This change do that tests (99.5%) consistently end up in $TESTDIR where they
started, thus making it simpler to extend them or move them around.
2012-06-11 01:40:51 +02:00
Thomas Arendsen Hein
6c60809dcc merge: show renamed on one and deleted on the other side in debug output 2012-05-23 21:34:29 +02:00
Martin Geisler
ae8ca6aff5 merge: make debug output easier to read
I always found it hard to figure out what the debug code meant without
the separators.
2011-12-09 17:34:53 +01:00
Martin Geisler
5a0135a6ca tests: remove redundant mkdir
There are still many tests that check that a bare 'hg init'
initializes the current directory.
2011-04-19 12:04:44 +02: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
Pradeepkumar Gayam
a8b5e99b7e tests: unify test-copy-move-merge 2010-08-18 04:26:20 +05:30