[PATCH v10 0/5] git checkout: optimise away lots of lstat() calls
From: Kjetil Barvik <hidden>
Date: 2016-06-15 22:45:58
Changes since version 9
--- patch 1/5 ---bug fix (missed optimisation):
If we have track_flags = FL_SYMLINK|FL_DIR, and:
cache => A/B/C/D/S (a symlink)
name => A/B/C (a directory)
The cache would return with a (cached) FL_DIR result as expected,
_but_ it would set the cache to "A/B/C", so we lose some information.
--- patch 4/5 ---bug fix: if we get a match from the cache for the name to invalidate, we reset the cache if we are not allowed to track directories (inside the invalidate_lstat_cache() function). Kjetil Barvik (5): lstat_cache(): more cache effective symlink/directory detection lstat_cache(): introduce has_symlink_or_noent_leading_path() function lstat_cache(): introduce has_dirs_only_path() function lstat_cache(): introduce invalidate_lstat_cache() function lstat_cache(): introduce clear_lstat_cache() function cache.h | 4 + entry.c | 34 +++----- symlinks.c | 263 ++++++++++++++++++++++++++++++++++++++++++++++--------- unpack-trees.c | 4 +- 4 files changed, 238 insertions(+), 67 deletions(-)