Re: [PATCH v4 08/10] commit: add short-circuit to paint_down_to_common()

2018-05-02 Thread Derrick Stolee
On 5/2/2018 9:05 AM, Jakub Narebski wrote: Derrick Stolee writes:     For a copy of the Linux repository, we measured the following     performance improvements:     git merge-base v3.3 v4.5     Before: 234 ms After: 208 ms Rel %: -11%     git merge-base

Re: [PATCH v4 08/10] commit: add short-circuit to paint_down_to_common()

2018-05-02 Thread Jakub Narebski
Derrick Stolee writes: > On 4/30/2018 6:19 PM, Jakub Narebski wrote: >> Derrick Stolee writes: [...] >>> @@ -831,6 +834,13 @@ static struct commit_list *paint_down_to_common(struct >>> commit *one, int n, struc >>> struct commit_list

Re: [PATCH v4 08/10] commit: add short-circuit to paint_down_to_common()

2018-05-01 Thread Derrick Stolee
On 4/30/2018 6:19 PM, Jakub Narebski wrote: Derrick Stolee writes: When running 'git branch --contains', the in_merge_bases_many() method calls paint_down_to_common() to discover if a specific commit is reachable from a set of branches. Commits with lower generation

Re: [PATCH v4 08/10] commit: add short-circuit to paint_down_to_common()

2018-04-30 Thread Jakub Narebski
Derrick Stolee writes: > When running 'git branch --contains', the in_merge_bases_many() > method calls paint_down_to_common() to discover if a specific > commit is reachable from a set of branches. Commits with lower > generation number are not needed to correctly answer

[PATCH v4 08/10] commit: add short-circuit to paint_down_to_common()

2018-04-25 Thread Derrick Stolee
When running 'git branch --contains', the in_merge_bases_many() method calls paint_down_to_common() to discover if a specific commit is reachable from a set of branches. Commits with lower generation number are not needed to correctly answer the containment query of in_merge_bases_many(). Add a