Merge branch 'bp/read-cache-parallel'
authorJunio C Hamano <gitster@pobox.com>
Fri, 19 Oct 2018 04:34:03 +0000 (13:34 +0900)
committerJunio C Hamano <gitster@pobox.com>
Fri, 19 Oct 2018 04:34:03 +0000 (13:34 +0900)
A new extension to the index file has been introduced, which allows
the file to be read in parallel.

* bp/read-cache-parallel:
read-cache: load cache entries on worker threads
ieot: add Index Entry Offset Table (IEOT) extension
read-cache: load cache extensions on a worker thread
config: add new index.threads config setting
eoie: add End of Index Entry (EOIE) extension
read-cache: clean up casting and byte decoding
read-cache.c: optimize reading index format v4

1  2 
Documentation/config.txt
config.c
read-cache.c
t/README
t/t1700-split-index.sh
Simple merge
diff --cc config.c
Simple merge
diff --cc read-cache.c
Simple merge
diff --cc t/README
index d8b04c35c01344534776a01e85b7f5f4f988cc62,8f5c0620eae414eaf55da6ab299f3fc00fc8dd14..88474896400308fa7a865ea1fb66f9e7d38f9a13
+++ b/t/README
@@@ -327,17 -327,11 +327,22 @@@ GIT_TEST_COMMIT_GRAPH=<boolean>, when t
  be written after every 'git commit' command, and overrides the
  'core.commitGraph' setting to true.
  
 +GIT_TEST_FSMONITOR=$PWD/t7519/fsmonitor-all exercises the fsmonitor
 +code path for utilizing a file system monitor to speed up detecting
 +new or changed files.
 +
 +GIT_TEST_INDEX_VERSION=<n> exercises the index read/write code path
 +for the index version specified.  Can be set to any valid version
 +(currently 2, 3, or 4).
 +
 +GIT_TEST_PRELOAD_INDEX=<boolean> exercises the preload-index code path
 +by overriding the minimum number of cache entries required per thread.
 +
+ GIT_TEST_INDEX_THREADS=<n> enables exercising the multi-threaded loading
+ of the index for the whole test suite by bypassing the default number of
+ cache entries and thread minimums. Setting this to 1 will make the
+ index loading single threaded.
  Naming Tests
  ------------
  
index 8f8807d1c1dc387a153a066153211899415e879f,ef9349bd70baf40059a1559e9c856584c39bf53f..3e618cad120f9cf692a1bc90d27d9c7ddb570135
@@@ -6,7 -6,12 +6,12 @@@ test_description='split index mode test
  
  # We need total control of index splitting here
  sane_unset GIT_TEST_SPLIT_INDEX
 -sane_unset GIT_FSMONITOR_TEST
+ # Testing a hard coded SHA against an index with an extension
+ # that can vary from run to run is problematic so we disable
+ # those extensions.
 +sane_unset GIT_TEST_FSMONITOR
+ sane_unset GIT_TEST_INDEX_THREADS
  
  test_expect_success 'enable split index' '
        git config splitIndex.maxPercentChange 100 &&