indexer.c
30.4 KB
-
indexer: Avoid one `mmap(2)`/`munmap(2)` pair per `git_indexer_append` call · 66a75fde
This change makes `append_to_pack` completely rely on `p_pwrite` to do all its I/O instead of splitting it between `p_pwrite` and a `mmap(2)`/`munmap(2)`+`memcpy(3)`. This saves a good chunk of user CPU time and avoids making two syscalls per round, but doesn't really cut down a lot of wall time (~1% on cloning the [git](https://github.com/git/git.git) repository).
lhchavez committed