Recommend Git's manyFiles feature#25977
Conversation
Git 2.24 introduced a feature flag for repositories with many files, see: https://github.blog/2019-11-03-highlights-from-git-2-24/#feature-macros Since Spack's Git repository contains roughly 8,500 files, it can be worthwhile to enable this, especially on slow file systems such as NFS: ``` $ hyperfine --warmup 3 'cd spack-default; git status' 'cd spack-manyfiles; git status' Benchmark #1: cd spack-default; git status Time (mean ± σ): 3.388 s ± 0.095 s [User: 256.2 ms, System: 625.8 ms] Range (min … max): 3.168 s … 3.535 s 10 runs Benchmark #2: cd spack-manyfiles; git status Time (mean ± σ): 168.7 ms ± 10.9 ms [User: 98.6 ms, System: 126.1 ms] Range (min … max): 144.8 ms … 188.0 ms 19 runs Summary 'cd spack-manyfiles; git status' ran 20.09 ± 1.42 times faster than 'cd spack-default; git status' ```
|
Will the config flag be ignored on older git versions that don't support the feature? |
I tested it with Git 2.17 and it just doesn't do anything then. |
|
It's not possible to ship a git config file within Spack where this is preset, is it? |
I don't think so. It needs to be set in Edit: To be precise, we could also put it into a separate config file (see https://stackoverflow.com/questions/18329621/how-to-store-a-git-config-as-part-of-the-repository) but then this file needs to be referenced in
|
adamjstewart
left a comment
There was a problem hiding this comment.
As long as older versions of git don't crash on this unsupported config setting, I agree with this feature!
|
@spackbot run pipeline |
|
I've started that pipeline for you! |
Git 2.24 introduced a feature flag for repositories with many files, see:
https://github.blog/2019-11-03-highlights-from-git-2-24/#feature-macros
Since Spack's Git repository contains roughly 8,500 files, it can be
worthwhile to enable this, especially on slow file systems such as NFS: