Document update for nd/unpack-trees-with-cache-tree
Fix an incorrect comment in the new code added in b4da37380b (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 4592e6080f (cache-tree: verify valid cache-tree in the test suite - 2018-08-18) Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Nguyễn Thái Ngọc Duy committed
Aug 25, 2018 at 15:02 UTC
5f4436a7211de7cd7552f6cf3bbb35147db1a070
2 files changed
+6
-2
t/README
+4
@@ -315,6 +315,10 @@ packs on demand. This normally only happens when the object size is
315
over 2GB. This variable forces the code path on any object larger than
316
<n> bytes.
317
318
+GIT_TEST_VALIDATE_INDEX_CACHE_ENTRIES=<boolean> checks that cache-tree
319
+records are valid when the index is written out or after a merge. This
320
+is mostly to catch missing invalidation. Default is true.
321
+
322
Naming Tests
323
------------
324
unpack-trees.c
+2
-2
@@ -676,8 +676,8 @@ static int index_pos_by_traverse_info(struct name_entry *names,
676
677
/*
678
* Fast path if we detect that all trees are the same as cache-tree at this
679
- * path. We'll walk these trees recursively using cache-tree/index instead of
680
- * ODB since already know what these trees contain.
679
+ * path. We'll walk these trees in an iterative loop using cache-tree/index
680
+ * instead of ODB since we already know what these trees contain.
681
*/
682
static int traverse_by_cache_tree(int pos, int nr_entries, int nr_names,
683
struct name_entry *names,