Files
git/builtin
Takuto Ikuta da78c688a3 checkout.c: enable fscache for checkout again
This is retry of #1419.

I added flush_fscache macro to flush cached stats after disk writing
with tests for regression reported in #1438 and #1442.

git checkout checks each file path in sorted order, so cache flushing does not
make performance worse unless we have large number of modified files in
a directory containing many files.

Using chromium repository, I tested `git checkout .` performance when I
delete 10 files in different directories.
With this patch:
TotalSeconds: 4.307272
TotalSeconds: 4.4863595
TotalSeconds: 4.2975562
Avg: 4.36372923333333

Without this patch:
TotalSeconds: 20.9705431
TotalSeconds: 22.4867685
TotalSeconds: 18.8968292
Avg: 20.7847136

I confirmed this patch passed all tests in t/ with core_fscache=1.

Signed-off-by: Takuto Ikuta <tikuta@chromium.org>
2026-04-09 01:59:55 +00:00
..
2026-04-01 10:28:18 -07:00
2026-02-20 08:13:58 -08:00
2026-03-31 20:43:14 -07:00
2025-07-23 08:15:18 -07:00
2025-07-23 08:15:18 -07:00
2025-07-23 08:15:18 -07:00
2025-07-23 08:15:18 -07:00
2025-07-01 14:46:38 -07:00
2026-03-31 20:43:14 -07:00
2025-08-22 13:13:20 -07:00
2026-04-02 13:30:44 -07:00
2026-03-25 12:58:05 -07:00
2026-03-12 14:09:07 -07:00
2026-03-23 09:20:30 -07:00
2026-03-23 08:33:10 -07:00
2025-08-21 13:47:00 -07:00
2026-03-23 08:33:10 -07:00
2026-03-31 20:43:14 -07:00
2025-07-23 08:15:18 -07:00
2026-02-20 08:13:58 -08:00
2026-03-31 20:43:14 -07:00
2025-07-23 08:15:18 -07:00
2026-03-24 12:31:31 -07:00
2025-09-16 11:37:06 -07:00
2025-08-21 13:46:59 -07:00