]> git.ipfire.org Git - thirdparty/git.git/blame - t/perf/p5310-pack-bitmaps.sh
Merge branch 'jk/clone-allow-bare-and-o-together'
[thirdparty/git.git] / t / perf / p5310-pack-bitmaps.sh
CommitLineData
bbcefa1f
JK
1#!/bin/sh
2
3test_description='Tests pack performance using bitmaps'
4. ./perf-lib.sh
9387fbd6 5. "${TEST_DIRECTORY}/perf/lib-bitmap.sh"
bbcefa1f 6
761416ef
AC
7test_lookup_pack_bitmap () {
8 test_expect_success 'start the test from scratch' '
9 rm -rf * .git
10 '
11
12 test_perf_large_repo
13
14 # note that we do everything through config,
15 # since we want to be able to compare bitmap-aware
16 # git versus non-bitmap git
17 #
18 # We intentionally use the deprecated pack.writebitmaps
19 # config so that we can test against older versions of git.
20 test_expect_success 'setup bitmap config' '
21 git config pack.writebitmaps true
22 '
23
24 # we need to create the tag up front such that it is covered by the repack and
25 # thus by generated bitmaps.
26 test_expect_success 'create tags' '
27 git tag --message="tag pointing to HEAD" perf-tag HEAD
28 '
29
30 test_perf "enable lookup table: $1" '
31 git config pack.writeBitmapLookupTable '"$1"'
32 '
33
34 test_pack_bitmap
35}
36
37test_lookup_pack_bitmap false
38test_lookup_pack_bitmap true
9639474b 39
bbcefa1f 40test_done