3 test_description='performance of fetches from bitmapped packs'
8 test_expect_success 'create bitmapped server repo' '
9 git config pack.writebitmaps true &&
10 git config pack.writebitmaphashcache true &&
14 # simulate a fetch from a repository that last fetched N days ago, for
15 # various values of N. We do so by following the first-parent chain,
16 # and assume the first entry in the chain that is N days older than the current
17 # HEAD is where the HEAD would have been then.
18 for days in 1 2 4 8 16 32 64 128; do
19 title=$(printf '%10s' "($days days)")
20 test_expect_success "setup revs from $days days ago" '
21 now=$(git log -1 --format=%ct HEAD) &&
22 then=$(($now - ($days * 86400))) &&
23 tip=$(git rev-list -1 --first-parent --until=$then HEAD) &&
30 test_perf "server $title" '
31 git pack-objects --stdout --revs \
32 --thin --delta-base-offset \
36 test_size "size $title" '
40 test_perf "client $title" '
41 git index-pack --stdin --fix-thin <tmp.pack