Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-07-07 Thread Junio C Hamano
David Turner writes: >> I am not convinced that doing an equivalent of write-tree when you >> switch branches is the right approach in the first place. You will >> eventually write it out as a tree, and having a relatively undamaged >> cache-tree will help you when you do so, but spending the cy

Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-07-05 Thread David Turner
On Tue, 2014-07-01 at 13:15 -0700, Junio C Hamano wrote: > David Turner writes: > > > When git checkout checks out a branch, create or update the > > cache-tree so that subsequent operations are faster. > > > > Signed-off-by: David Turner > > --- > > builtin/checkout.c| 8 > > cac

Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-07-01 Thread David Turner
On Tue, 2014-07-01 at 14:03 -0700, Junio C Hamano wrote: > David Turner writes: > > > On Tue, 2014-07-01 at 06:16 +0200, Torsten Bögershausen wrote: > >> diff --git a/t/t0090-cache-tree.sh b/t/t0090-cache-tree.sh > >> index 6c33e28..7c60675 100755 > >> --- a/t/t0090-cache-tree.sh > >> +++ b/t/t00

Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-07-01 Thread Junio C Hamano
David Turner writes: > When git checkout checks out a branch, create or update the > cache-tree so that subsequent operations are faster. > > Signed-off-by: David Turner > --- Could you number your patches e.g. [PATCH v4 1/3] and/or summarize below the three-dash line what got updated since the

Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-07-01 Thread Junio C Hamano
David Turner writes: > On Tue, 2014-07-01 at 06:16 +0200, Torsten Bögershausen wrote: >> diff --git a/t/t0090-cache-tree.sh b/t/t0090-cache-tree.sh >> index 6c33e28..7c60675 100755 >> --- a/t/t0090-cache-tree.sh >> +++ b/t/t0090-cache-tree.sh >> @@ -85,9 +85,22 @@ test_expect_success 'reset --har

Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-07-01 Thread Junio C Hamano
David Turner writes: > When git checkout checks out a branch, create or update the > cache-tree so that subsequent operations are faster. > > Signed-off-by: David Turner > --- > builtin/checkout.c| 8 > cache-tree.c | 5 +++-- > t/t0090-cache-tree.sh | 15 ++-

Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-07-01 Thread David Turner
On Tue, 2014-07-01 at 06:16 +0200, Torsten Bögershausen wrote: > diff --git a/t/t0090-cache-tree.sh b/t/t0090-cache-tree.sh > index 6c33e28..7c60675 100755 > --- a/t/t0090-cache-tree.sh > +++ b/t/t0090-cache-tree.sh > @@ -85,9 +85,22 @@ test_expect_success 'reset --hard without index gives > cache

Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-06-30 Thread Torsten Bögershausen
diff --git a/t/t0090-cache-tree.sh b/t/t0090-cache-tree.sh index 6c33e28..7c60675 100755 --- a/t/t0090-cache-tree.sh +++ b/t/t0090-cache-tree.sh @@ -85,9 +85,22 @@ test_expect_success 'reset --hard without index gives cache-tree' ' test_shallow_cache_tree ' -test_expect_failure 'check

Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-06-30 Thread Junio C Hamano
Duy Nguyen writes: > I wonder if we should do this in !opts->force code path only. In the > opts->force code path we could use prime_cache_tree() (like > read-tree), which is supposedly faster... Nobody sane should be constantly running "checkout -f", so even if priming from existing tree object

Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-06-29 Thread Junio C Hamano
David Turner writes: > When git checkout checks out a branch, create or update the > cache-tree so that subsequent operations are faster. > > Signed-off-by: David Turner > --- > builtin/checkout.c| 4 > cache-tree.c | 22 -- > cache-tree.h | 1 +

Re: [PATCH 1/3] cache-tree: Create/update cache-tree on checkout

2014-06-28 Thread Duy Nguyen
On Sat, Jun 28, 2014 at 7:20 AM, David Turner wrote: > When git checkout checks out a branch, create or update the > cache-tree so that subsequent operations are faster. > > Signed-off-by: David Turner > --- > builtin/checkout.c| 4 > cache-tree.c | 22 -- >