]> granicus.if.org Git - git/commitdiff
Merge branch 'nd/split-index'
authorJunio C Hamano <gitster@pobox.com>
Wed, 16 Jul 2014 18:25:40 +0000 (11:25 -0700)
committerJunio C Hamano <gitster@pobox.com>
Wed, 16 Jul 2014 18:25:40 +0000 (11:25 -0700)
An experiment to use two files (the base file and incremental
changes relative to it) to represent the index to reduce I/O cost
of rewriting a large index when only small part of the working tree
changes.

* nd/split-index: (32 commits)
  t1700: new tests for split-index mode
  t2104: make sure split index mode is off for the version test
  read-cache: force split index mode with GIT_TEST_SPLIT_INDEX
  read-tree: note about dropping split-index mode or index version
  read-tree: force split-index mode off on --index-output
  rev-parse: add --shared-index-path to get shared index path
  update-index --split-index: do not split if $GIT_DIR is read only
  update-index: new options to enable/disable split index mode
  split-index: strip pathname of on-disk replaced entries
  split-index: do not invalidate cache-tree at read time
  split-index: the reading part
  split-index: the writing part
  read-cache: mark updated entries for split index
  read-cache: save deleted entries in split index
  read-cache: mark new entries for split index
  read-cache: split-index mode
  read-cache: save index SHA-1 after reading
  entry.c: update cache_changed if refresh_cache is set in checkout_entry()
  cache-tree: mark istate->cache_changed on prime_cache_tree()
  cache-tree: mark istate->cache_changed on cache tree update
  ...

17 files changed:
1  2 
.gitignore
Makefile
builtin/apply.c
builtin/blame.c
builtin/checkout.c
builtin/clone.c
builtin/commit.c
builtin/merge.c
builtin/mv.c
builtin/reset.c
builtin/update-index.c
cache.h
merge-recursive.c
merge.c
read-cache.c
sequencer.c
unpack-trees.c

diff --cc .gitignore
Simple merge
diff --cc Makefile
Simple merge
diff --cc builtin/apply.c
Simple merge
diff --cc builtin/blame.c
Simple merge
Simple merge
diff --cc builtin/clone.c
Simple merge
Simple merge
diff --cc builtin/merge.c
Simple merge
diff --cc builtin/mv.c
Simple merge
diff --cc builtin/reset.c
Simple merge
Simple merge
diff --cc cache.h
Simple merge
Simple merge
diff --cc merge.c
Simple merge
diff --cc read-cache.c
index 6a45966ec499b47efbc76719046b53633e8839a1,342fe52fdaf91695e1d75ea8aa73d87ac5405dfa..5d3c8bd4aaffda9915a3fd62d9d9800f4ac8baff
@@@ -1827,9 -1857,7 +1904,8 @@@ static int has_racy_timestamp(struct in
  void update_index_if_able(struct index_state *istate, struct lock_file *lockfile)
  {
        if ((istate->cache_changed || has_racy_timestamp(istate)) &&
-           verify_index(istate) && !write_index(istate, lockfile->fd))
-               commit_locked_index(lockfile);
-       else
++          verify_index(istate) &&
+           write_locked_index(istate, lockfile, COMMIT_LOCK))
                rollback_lock_file(lockfile);
  }
  
diff --cc sequencer.c
Simple merge
diff --cc unpack-trees.c
Simple merge