Skip to content

Commit ba70846

Browse files
pcloudsdscho
authored andcommitted
Document update for nd/unpack-trees-with-cache-tree
Fix an incorrect comment in the new code added in b4da373 (unpack-trees: optimize walking same trees with cache-tree - 2018-08-18) and document about the new test variable that is enabled by default in test-lib.sh in 4592e60 (cache-tree: verify valid cache-tree in the test suite - 2018-08-18) Signed-off-by: Nguyễn Thái Ngọc Duy <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 0637198 commit ba70846

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

t/README

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -319,6 +319,10 @@ GIT_TEST_OE_DELTA_SIZE=<n> exercises the uncomon pack-objects code
319319
path where deltas larger than this limit require extra memory
320320
allocation for bookkeeping.
321321

322+
GIT_TEST_VALIDATE_INDEX_CACHE_ENTRIES=<boolean> checks that cache-tree
323+
records are valid when the index is written out or after a merge. This
324+
is mostly to catch missing invalidation. Default is true.
325+
322326
Naming Tests
323327
------------
324328

unpack-trees.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -680,8 +680,8 @@ static int index_pos_by_traverse_info(struct name_entry *names,
680680

681681
/*
682682
* Fast path if we detect that all trees are the same as cache-tree at this
683-
* path. We'll walk these trees recursively using cache-tree/index instead of
684-
* ODB since already know what these trees contain.
683+
* path. We'll walk these trees in an iterative loop using cache-tree/index
684+
* instead of ODB since we already know what these trees contain.
685685
*/
686686
static int traverse_by_cache_tree(int pos, int nr_entries, int nr_names,
687687
struct name_entry *names,

0 commit comments

Comments
 (0)