Hi,
I noticed some slowness when fast-importing data from the Firefox mercurial
repository, where fast-import spends more than 5 minutes importing ~2000
revisions of one particular file. I reduced a testcase while still
using real data. One could synthesize data with kind of the same
properties, b
Hi Junio,
Le 28/06/2018 à 23:40, Junio C Hamano a écrit :
> * ag/rebase-i-append-todo-help (2018-06-14) 2 commits
> - rebase--interactive: rewrite append_todo_help() in C
> - Merge branch 'ag/rebase-p' into ag/rebase-i-append-todo-help
> (this branch is used by ag/rebase-i-rewrite-todo.)
>
>
Hi Junio,
On Thu, 28 Jun 2018, Junio C Hamano wrote:
> What I meant by "many separte grep calls" was to contrast these two
> approaches:
>
> * Have one typical output spelled out as "expect", take an output
>from an actual run into "actual", make them comparable and then
>do a compare (
Hi Peff,
On Thu, 28 Jun 2018, Jeff King wrote:
> On Thu, Jun 28, 2018 at 10:27:32AM -0700, Junio C Hamano wrote:
>
> > Johannes Schindelin writes:
> >
> > >> I.e.:
> > >>
> > >> FOO='with spaces'
> > >> BAR=$FOO sh -c 'echo $BAR'
> > >>
> > >> works just fine.
> > >
> > > $ x="two spa
From: Johannes Schindelin
In ed32b788c06 (version --build-options: report commit, too, if
possible, 2017-12-15), we introduced code to let `git version
--build-options` report the current commit from which the binaries were
built, if any.
To prevent erroneous commits from being reported (e.g. wh
When I tried recently to build macOS installers via Tim Harper's wonderful
project at https://github.com/timcharper/git_osx_installer, it worked (with a
couple of quirks), but it reported to be built from a commit that I first could
not place.
Turns out that the git_osx_installer project insist
On 6/27/2018 5:59 PM, Jonathan Tan wrote:
+int verify_commit_graph(struct repository *r, struct commit_graph *g)
I haven't had the time to review this patch set, but I did rebase my
object store refactoring [1] on this and wrote a test:
static void test_verify_commit_graph(const char *gitd
Hi Elijah
On 27/06/18 08:23, Elijah Newren wrote:
> git-rebase has lots of options that are mutually incompatible. Even among
> aspects of its behavior that is common to all rebase types, it has a number
> of inconsistencies. This series tries to document, fix, and/or warn users
> about many of
On 6/28/2018 6:42 PM, Stefan Beller wrote:
On Thu, Jun 28, 2018 at 2:40 PM Junio C Hamano wrote:
* ds/commit-graph-fsck (2018-06-27) 22 commits
[...]
"git fsck" learns to make sure the optional commit-graph file is in
a sane state.
Is this ready for 'next'?
I hope so, as I plan to re
Hi Junio,
On Thu, 28 Jun 2018, Junio C Hamano wrote:
> Aaron Schrab writes:
>
> > Use configured comment character when generating comments about branches
> > in an instruction sheet. Failure to honor this configuration causes a
> > failure to parse the resulting instruction sheet.
> >
> > Sig
On 6/28/2018 9:21 PM, Stefan Beller wrote:
Add a repository argument to allow callers of lookup_commit to be more
specific about which repository to handle. This is a small mechanical
change; it doesn't change the implementation to handle repositories
other than the_repository yet.
As with the p
On 6/28/2018 9:22 PM, Stefan Beller wrote:
Add a repository argument to allow the callers of parse_commit_buffer
to be more specific about which repository to act on. This is a small
mechanical change; it doesn't change the implementation to handle
repositories other than the_repository yet.
As
On 6/28/2018 9:21 PM, Stefan Beller wrote:
This continues the elimination of global variables in the object store and
teaches lookup_commit[_reference] and alike to handle a_repository.
This is also available as
https://github.com/stefanbeller/git/tree/object-store-lookup-commit
or applies on to
This rewrites (the misnamed) setup_reflog_action() from shell to C. The
new version is called prepare_branch_to_be_rebased().
A new command is added to rebase--helper.c, “checkout-base”, as well as
a new flag, “verbose”, to avoid silencing the output of the checkout
operation called by checkout_ba
This patch series rewrites the reflog operations from shell to C. This
is part of the effort to rewrite interactive rebase in C.
The first commit is dedicated to creating a function to silence a
command, as the sequencer will do in several places with these patches.
This branch is based on ag/re
This rewrites checkout_onto() from shell to C.
A new command (“checkout-onto”) is added to rebase--helper.c. The shell
version is then stripped.
Signed-off-by: Alban Gruin
---
builtin/rebase--helper.c | 7 ++-
git-rebase--interactive.sh | 25 -
sequencer.c
This adds a new function, run_command_silent_on_success(), to
redirect the stdout and stderr of a command to a strbuf, and then to run
that command. This strbuf is printed only if the command fails. It is
functionnaly similar to output() from git-rebase.sh.
run_git_commit() is then refactored to u
Johannes Schindelin writes:
> In short: the code is fine, but yes, I had to convince myself by looking
> through the code. (Hinting at a possible improvement of the commit
> message.)
Yup, that exactly was what I was hoping readers to realize.
Signed-off-by: Derrick Stolee
---
builtin/remote.c | 1 +
commit-reach.c | 52
commit-reach.h | 2 ++
http-push.c | 1 +
remote.c | 48 +---
remote.h | 1 -
6 files changed, 57 in
This RFC is a bit unpolished because I was mostly seeing where the idea
could go. I wanted to achieve the following:
1. Consolidate several different commit walks into one file
2. Reduce duplicate reachability logic
3. Increase testability (correctness and performance)
4. Improve performance of re
Signed-off-by: Derrick Stolee
---
commit-reach.c | 61 +
commit-reach.h | 8 +++
upload-pack.c | 62 +++---
3 files changed, 72 insertions(+), 59 deletions(-)
diff --git a/commit-reach.c b/commit-re
Signed-off-by: Derrick Stolee
---
Makefile | 1 +
commit-reach.c | 359 +
commit-reach.h | 41 ++
commit.c | 358
4 files changed, 401 insertions(+), 358 deletions(-)
create mode 1
The ref_newer method is used by 'git push' to detect if a force-push is
requried. This method does not use any kind of cutoff when walking, so
in the case of a force-push will walk all reachable commits.
The is_descendant_of method already uses paint_down_to_common along with
cutoffs. By translati
Signed-off-by: Derrick Stolee
---
t/helper/test-reach.c | 2 ++
t/t6600-test-reach.sh | 25 +
2 files changed, 27 insertions(+)
diff --git a/t/helper/test-reach.c b/t/helper/test-reach.c
index 88639a2945..14aaef5bff 100644
--- a/t/helper/test-reach.c
+++ b/t/helper/test-
Signed-off-by: Derrick Stolee
---
commit-reach.c| 52 +++
commit-reach.h| 4 +++-
t/helper/test-reach.c | 7 --
t/t6600-test-reach.sh | 51 +++---
upload-pack.c | 2 +-
5 files changed, 105
The is_descendant_of method previously used in_merge_bases() to check if
the commit can reach any of the commits in the provided list. This had
two performance problems:
1. The performance is quadratic in worst-case.
2. A single in_merge_bases() call requires walking beyond the target
commit i
Signed-off-by: Derrick Stolee
---
commit-reach.c | 119 +++
commit-reach.h | 44 +--
fast-import.c | 1 +
ref-filter.c | 147 +++--
4 files changed, 141 insertions(+), 170 deletions(-)
diff --git a/
In anticipation of moving the reachable() method to commit-reach.c,
modify the prototype to be more generic to flags known outside of
upload-pack.c. Also rename 'want' to 'from' to make the statement
more clear outside of the context of haves/wants negotiation.
Signed-off-by: Derrick Stolee
---
Signed-off-by: Derrick Stolee
---
t/t6600-test-reach.sh | 26 ++
1 file changed, 26 insertions(+)
diff --git a/t/t6600-test-reach.sh b/t/t6600-test-reach.sh
index c9337b6b46..0f60db9c60 100755
--- a/t/t6600-test-reach.sh
+++ b/t/t6600-test-reach.sh
@@ -78,4 +78,30 @@ test
In anticipation of consolidating all commit reachability algorithms,
refactor ok_to_give_up() in order to allow splitting its logic into
an external method.
Signed-off-by: Derrick Stolee
---
upload-pack.c | 28 +---
1 file changed, 17 insertions(+), 11 deletions(-)
diff
The can_all_from_reach_with_flags() algorithm is currently quadratic in
the worst case, because it calls the reachable() method for every 'from'
without tracking which commits have already been walked or which can
already reach a commit in 'to'.
Rewrite the algorithm to walk each commit a constant
---
Makefile | 1 +
t/helper/test-reach.c | 123 ++
t/helper/test-tool.c | 1 +
t/helper/test-tool.h | 1 +
t/t6600-test-reach.sh | 81
5 files changed, 207 insertions(+)
create mode 100644 t/helper/test-re
Jonathan Tan writes:
>> fetch is a perfect example of supporting all three. I can do
>>
>> git fetch origin SHA1
>> git fetch origin master
>> git fetch origin refs/heads/*:refs/heads/*
>
> OK, Brandon managed to convince me that this is fine. I've included glob
> support, supporting the s
Stefan Beller writes:
> Over the years of contributing to open source, I realized the world of
> open source is smaller than I originally thought and a name is still
> a pretty unique thing. So let's assume these two author idents are the
> same person.
>
> In 10813e0d3c7 (.mailmap: update long-l
Alban Gruin writes:
> + git rebase--helper --prepare-branch "$switch_to" ${verbose:+--verbose}
> init_basic_state
>
> init_revisions_and_shortrevisions
> diff --git a/sequencer.c b/sequencer.c
> index d9545b366..dd0cf3cb5 100644
> --- a/sequencer.c
> +++ b/sequencer.c
> @@ -3134
Alban Gruin writes:
> This patch series rewrites the reflog operations from shell to C. This
> is part of the effort to rewrite interactive rebase in C.
>
> The first commit is dedicated to creating a function to silence a
> command, as the sequencer will do in several places with these patches.
This RFC is available as a GitHub pull request [1].
Thanks,
-Stolee
[1] https://github.com/derrickstolee/git/pull/8
Stefan Beller writes:
> This is a continuation of 94b410bba86 (.mailmap: Map email
> addresses to names, 2013-07-12), merging names that are
> spelled differently but have the same author email to the
> same person.
>
> Most spellings differed in accents or the order of names.
Thanks. This one
Stefan Beller writes:
> There are multiple author idents who have different email addresses, but
> the same name; assume they are the same person, as the world of open source
> is actually rather small.
Thanks for an interesting experiment. As with 2/3, I suspect that
most of the contents in th
Stefan Beller writes:
> This continues the elimination of global variables in the object store and
> teaches lookup_commit[_reference] and alike to handle a_repository.
>
> This is also available as
> https://github.com/stefanbeller/git/tree/object-store-lookup-commit
> or applies on top of 02f70
Junio C Hamano writes:
> One technique these (not just this) recent efforts seem to be
> forgetting is to introduce "new" names that take a_repo and then
> make the existing one a thin wrapper that calls the new one with
> &the_repo as the argument.
FWIW, here is how I am resolving semantic conf
Junio C Hamano writes:
> Let's aggregate these topics into a single topic, and perhaps call
> it ag/rebase-i-in-c or something like that. Pretending as if they
> are separately replaceable does not make much sense, as you are not
> rerolling the earlier one and keep going forward with producing
On Fri, Jun 29, 2018 at 11:03 AM Junio C Hamano wrote:
>
> Junio C Hamano writes:
>
> > One technique these (not just this) recent efforts seem to be
> > forgetting is to introduce "new" names that take a_repo and then
> > make the existing one a thin wrapper that calls the new one with
> > &the_
On Fri, Jun 29, 2018 at 10:42 AM Junio C Hamano wrote:
>
> Stefan Beller writes:
>
> > There are multiple author idents who have different email addresses, but
> > the same name; assume they are the same person, as the world of open source
> > is actually rather small.
>
> Thanks for an interesti
The purpose of this configuration option is to prevent your emails from
blowing up on SMTP servers (rather than Extended SMTP servers). However,
I find it often confuses people whose patches are otherwise correct, and
they don't know how to solve the issue.
I haven't seen an SMTP server in a very
Stefan Beller writes:
> On Fri, Jun 29, 2018 at 11:03 AM Junio C Hamano wrote:
>>
>> Junio C Hamano writes:
>>
>> > One technique these (not just this) recent efforts seem to be
>> > forgetting is to introduce "new" names that take a_repo and then
>> > make the existing one a thin wrapper that
Stefan Beller writes:
>> It may be even better if we can arraange the author of the patch to
>> be the one who is involved, with "Helped-by: Stefan".
>
> ok, I'll think how I can help but not write the code.
I do not think there is any code required. All it takes is a
volunteer coordinater who
Stefan Beller writes:
>> * jt/remove-pack-bitmap-global (2018-06-21) 2 commits
>> - pack-bitmap: add free function
>> - pack-bitmap: remove bitmap_git global variable
>>
>> The effort to move globals to per-repository in-core structure
>> continues.
>
> This is mostly done, though Peff seems
On Fri, Jun 29, 2018 at 3:18 AM Mike Hommey wrote:
>
> Hi,
>
> I noticed some slowness when fast-importing data from the Firefox mercurial
> repository, where fast-import spends more than 5 minutes importing ~2000
> revisions of one particular file. I reduced a testcase while still
> using real da
This patch was written originally for mercurial at
https://phab.mercurial-scm.org/rHGc420792217c89622482005c99e959b9071c109c5
changeset: 36674:c420792217c8
user:Jun Wu
date:Sat Mar 03 12:39:11 2018 -0800
files: mercurial/thirdparty/xdiff/xdiffi.c
descri
On Fri, Jun 29, 2018 at 01:14:52PM -0700, Stefan Beller wrote:
> Interesting pieces regarding performance:
>
> c420792217c8 xdiff: reduce indent heuristic overhead
> https://phab.mercurial-scm.org/rHGc420792217c89622482005c99e959b9071c109c5
>
> f33a87cf60cc xdiff: add a preprocessing step that t
+cc Jun Wu, original author of these patches
On Fri, Jun 29, 2018 at 1:39 PM Jeff King wrote:
> > Interesting pieces regarding performance:
> >
> > c420792217c8 xdiff: reduce indent heuristic overhead
> > https://phab.mercurial-scm.org/rHGc420792217c89622482005c99e959b9071c109c5
Going by the ma
On Thu, Jun 28 2018, Junio C Hamano wrote:
> The tip of 'next' has been rewound and it currently has only 4
> topics. Quite a many topics are cooking in 'pu' and need to be
> sifted into good bins (for 'next') and the remainder. Help is
> appreciated in that area ;-)
Per my
https://public-inb
Stefan Beller writes:
> This patch was written originally for mercurial at
> https://phab.mercurial-scm.org/rHGc420792217c89622482005c99e959b9071c109c5
>
> changeset: 36674:c420792217c8
> user:Jun Wu
> date:Sat Mar 03 12:39:11 2018 -0800
> files: mercurial
Hi Derrick,
> +/* Remember to update object flag allocation in object.h */
> +#define PARENT1 (1u<<16)
> +#define PARENT2 (1u<<17)
> +#define STALE (1u<<18)
> +#define RESULT (1u<<19)
Something is up with whitespaces here, apart from that this patch
looks good.
Hi Derrick,
> +struct ref_filter_cbdata {
> + struct ref_array *array;
> + struct ref_filter *filter;
> + struct contains_cache contains_cache;
> + struct contains_cache no_contains_cache;
These members also seem to be moved whitespace-inconsistently.
Could you clarify in
Hi Derrick,
> -static int ok_to_give_up(void)
> +static int can_all_from_reach_with_flag(struct object_array from,
This method is hard to read; at first I thought you missed a word,
but then I realized that it asks "can all 'from' members reach
['something'] and we pass in the 'flag', so maybe
Hi Derrick,
> +static int reachable(struct commit *from, int with_flag, int assign_flag,
> time_t min_commit_date)
[...]
> + if (commit->date < min_commit_date)
> + continue;
[...]
> +int can_all_from_reach_with_flag(struct object_array from,
> +
Derrick Stolee writes:
> Signed-off-by: Derrick Stolee
> ---
> Makefile | 1 +
> commit-reach.c | 359 +
> commit-reach.h | 41 ++
> commit.c | 358
> 4 files changed, 401 inserti
On Fri, Jun 29, 2018 at 9:13 AM Derrick Stolee wrote:
> +# Construct a grid-like commit graph with points (x,y)
> +# with 1 <= x <= 10, 1 <= y <= 10, where (x,y) has
> +# parents (x-1, y) and (x, y-1), keeping in mind that
> +# we drop a parent if a coordinate is nonpositive.
> +#
> +#
Derrick Stolee writes:
> +int commit_contains(struct ref_filter *filter, struct commit *commit,
> + struct commit_list *list, struct contains_cache *cache)
This is a symbol that is used to be file-local private. Is it named
appropriately in the new context, which is "globally vi
Derrick Stolee writes:
> In anticipation of moving the reachable() method to commit-reach.c,
> modify the prototype to be more generic to flags known outside of
> upload-pack.c. Also rename 'want' to 'from' to make the statement
> more clear outside of the context of haves/wants negotiation.
FWI
On Fri, Jun 29, 2018 at 9:13 AM Derrick Stolee wrote:
>
> Signed-off-by: Derrick Stolee
> ---
> t/t6600-test-reach.sh | 26 ++
> 1 file changed, 26 insertions(+)
>
> diff --git a/t/t6600-test-reach.sh b/t/t6600-test-reach.sh
> index c9337b6b46..0f60db9c60 100755
> --- a/t
On Fri, Jun 29 2018, Mike Hommey wrote:
> I noticed some slowness when fast-importing data from the Firefox mercurial
> repository, where fast-import spends more than 5 minutes importing ~2000
> revisions of one particular file. I reduced a testcase while still
> using real data. One could synth
On 06/29, Junio C Hamano wrote:
> Stefan Beller writes:
>
> > On Fri, Jun 29, 2018 at 11:03 AM Junio C Hamano wrote:
> >>
> >> Junio C Hamano writes:
> >>
> >> > One technique these (not just this) recent efforts seem to be
> >> > forgetting is to introduce "new" names that take a_repo and then
> > That is the way it should work, but after thinking about it once more, I
> > realize that it isn't.
> >
> > opt->shallow_file is not set to anything. And fetch-pack updates the
> > shallow file by itself (at least, that is my understanding of
> > update_shallow() in fetch-pack.c) before fetch c
On Fri, Jun 29, 2018 at 9:13 AM Derrick Stolee wrote:
>
> The can_all_from_reach_with_flags() algorithm is currently quadratic in
> the worst case, because it calls the reachable() method for every 'from'
> without tracking which commits have already been walked or which can
> already reach a comm
Hi Derrick,
On Fri, Jun 29, 2018 at 9:13 AM Derrick Stolee wrote:
>
> The is_descendant_of method previously used in_merge_bases() to check if
> the commit can reach any of the commits in the provided list. This had
> two performance problems:
>
> 1. The performance is quadratic in worst-case.
>
>
On Sat, Jun 30, 2018 at 12:10:24AM +0200, Ævar Arnfjörð Bjarmason wrote:
>
> On Fri, Jun 29 2018, Mike Hommey wrote:
>
> > I noticed some slowness when fast-importing data from the Firefox mercurial
> > repository, where fast-import spends more than 5 minutes importing ~2000
> > revisions of one
From: Jun Wu
This patch was written originally for mercurial at [1],
adding a limit on how long we'd be looking for an
optimal indent heuristic. Choose the limit high enough
to only limit edge cases.
Adds some threshold to avoid expensive cases, like:
```
#!python
open('a', 'w')
Excerpts from Stefan Beller's message of 2018-06-29 16:37:41 -0700:
> [...]
> Jun, Junio
>
> By changing the authorship we'd want to have a sign off from the original
> author,
> before applying; in the previous attempt, I was merely taking the code from
> mercurial as their copy of xdiff is also
On 6/29/2018 5:38 PM, Stefan Beller wrote:
Hi Derrick,
+struct ref_filter_cbdata {
+ struct ref_array *array;
+ struct ref_filter *filter;
+ struct contains_cache contains_cache;
+ struct contains_cache no_contains_cache;
These members also seem to be moved whitespace-i
On 6/29/2018 5:47 PM, Stefan Beller wrote:
Hi Derrick,
+static int reachable(struct commit *from, int with_flag, int assign_flag,
time_t min_commit_date)
[...]
+ if (commit->date < min_commit_date)
+ continue;
[...]
+int can_all_from_reach_with_flag(str
On 6/29/2018 5:54 PM, Stefan Beller wrote:
On Fri, Jun 29, 2018 at 9:13 AM Derrick Stolee wrote:
+# Construct a grid-like commit graph with points (x,y)
+# with 1 <= x <= 10, 1 <= y <= 10, where (x,y) has
+# parents (x-1, y) and (x, y-1), keeping in mind that
+# we drop a parent if a coordinat
Col. Hussein Kharmusch
75 matches
Mail list logo