Re:
- From
Alex Riesen <raa.lkml@gmail.com>
- Date
- May 8, 2009, 08:17 UTC
- Message-ID
- <81b0412b0905080117v3aad0c44o7b3bbcc7fe70d3b1@mail.gmail.com>
- In-Reply-To
- <alpine.LFD.2.01.0905071446500.4983@localhost.localdomain>
2009/5/7 Linus Torvalds <torvalds@linux-foundation.org>:
Show 5 quoted lines
> > Somebody should check. It would be interesting to hear about whether this > makes a performance impact, especially with slow filesystems and/or other > operating systems that have a relatively higher cost for 'lstat()'. >
I did (cygwin). My guess, the improvement is completely dwarfed by the other overheads (like starting git and writing files).
# Without the patch real 11m22.338s user 0m54.629s sys 8m33.638s
# With checkout index preload real 11m14.361s user 0m46.609s sys 7m56.300s
The script:
#!/bin/sh
if [ "$1" = setup ]; then
for i in 1 2 3 4
do
n=$(date)
for f in `seq 1 10000`
do
echo "$n" >file$f
done
git add .
printf "Commit $i:"
git commit -m"$n"
done
exit
fiexport GIT_EXEC_PATH=/d/git-win
time for f in `seq 1 10`
do
$GIT_EXEC_PATH/git checkout master~3 &&
$GIT_EXEC_PATH/git checkout master~2 &&
$GIT_EXEC_PATH/git checkout master~1 &&
$GIT_EXEC_PATH/git checkout master
done
exit