Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
internal/mod/modpkgload: don't use modimports.PackageFiles twice
This reduces the number of syscalls we do when loading one or all packages by about 10% and 2% respectively, going from $ strace -f -t -e trace=file cue fmt ./internal/ci |& grep '/home/mvdan/src' | wc -l 108 $ strace -f -t -e trace=file cue fmt ./... |& grep '/home/mvdan/src' | wc -l 5365 to $ strace -f -t -e trace=file cue fmt ./internal/ci |& grep '/home/mvdan/src' | wc -l 96 $ strace -f -t -e trace=file cue fmt ./... |& grep '/home/mvdan/src' | wc -l 5256 Updates #3155. Signed-off-by: Daniel Martí <mvdan@mvdan.cc> Change-Id: I8a5bbe33b0d9656805a20a082be90faedd679122
- Loading branch information