##// END OF EJS Templates
test: update `test-sparse-revlog` output...
marmoute -
r50120:58a814d0 default
parent child Browse files
Show More
@@ -1,147 +1,152 b''
1 ====================================
1 ====================================
2 Test delta choice with sparse revlog
2 Test delta choice with sparse revlog
3 ====================================
3 ====================================
4
4
5 Sparse-revlog usually shows the most gain on Manifest. However, it is simpler
5 Sparse-revlog usually shows the most gain on Manifest. However, it is simpler
6 to general an appropriate file, so we test with a single file instead. The
6 to general an appropriate file, so we test with a single file instead. The
7 goal is to observe intermediate snapshot being created.
7 goal is to observe intermediate snapshot being created.
8
8
9 We need a large enough file. Part of the content needs to be replaced
9 We need a large enough file. Part of the content needs to be replaced
10 repeatedly while some of it changes rarely.
10 repeatedly while some of it changes rarely.
11
11
12 $ bundlepath="$TESTDIR/artifacts/cache/big-file-churn.hg"
12 $ bundlepath="$TESTDIR/artifacts/cache/big-file-churn.hg"
13
13
14 $ expectedhash=`cat "$bundlepath".md5`
14 $ expectedhash=`cat "$bundlepath".md5`
15
15
16 #if slow
16 #if slow
17
17
18 $ if [ ! -f "$bundlepath" ]; then
18 $ if [ ! -f "$bundlepath" ]; then
19 > "$TESTDIR"/artifacts/scripts/generate-churning-bundle.py > /dev/null
19 > "$TESTDIR"/artifacts/scripts/generate-churning-bundle.py > /dev/null
20 > fi
20 > fi
21
21
22 #else
22 #else
23
23
24 $ if [ ! -f "$bundlepath" ]; then
24 $ if [ ! -f "$bundlepath" ]; then
25 > echo 'skipped: missing artifact, run "'"$TESTDIR"'/artifacts/scripts/generate-churning-bundle.py"'
25 > echo 'skipped: missing artifact, run "'"$TESTDIR"'/artifacts/scripts/generate-churning-bundle.py"'
26 > exit 80
26 > exit 80
27 > fi
27 > fi
28
28
29 #endif
29 #endif
30
30
31 $ currenthash=`f -M "$bundlepath" | cut -d = -f 2`
31 $ currenthash=`f -M "$bundlepath" | cut -d = -f 2`
32 $ if [ "$currenthash" != "$expectedhash" ]; then
32 $ if [ "$currenthash" != "$expectedhash" ]; then
33 > echo 'skipped: outdated artifact, md5 "'"$currenthash"'" expected "'"$expectedhash"'" run "'"$TESTDIR"'/artifacts/scripts/generate-churning-bundle.py"'
33 > echo 'skipped: outdated artifact, md5 "'"$currenthash"'" expected "'"$expectedhash"'" run "'"$TESTDIR"'/artifacts/scripts/generate-churning-bundle.py"'
34 > exit 80
34 > exit 80
35 > fi
35 > fi
36
36
37 $ cat >> $HGRCPATH << EOF
37 $ cat >> $HGRCPATH << EOF
38 > [format]
38 > [format]
39 > sparse-revlog = yes
39 > sparse-revlog = yes
40 > maxchainlen = 15
40 > maxchainlen = 15
41 > [storage]
41 > [storage]
42 > revlog.optimize-delta-parent-choice = yes
42 > revlog.optimize-delta-parent-choice = yes
43 > revlog.reuse-external-delta = no
43 > revlog.reuse-external-delta = no
44 > EOF
44 > EOF
45 $ hg init sparse-repo
45 $ hg init sparse-repo
46 $ cd sparse-repo
46 $ cd sparse-repo
47 $ hg unbundle $bundlepath
47 $ hg unbundle $bundlepath
48 adding changesets
48 adding changesets
49 adding manifests
49 adding manifests
50 adding file changes
50 adding file changes
51 added 5001 changesets with 5001 changes to 1 files (+89 heads)
51 added 5001 changesets with 5001 changes to 1 files (+89 heads)
52 new changesets 9706f5af64f4:d9032adc8114 (5001 drafts)
52 new changesets 9706f5af64f4:d9032adc8114 (5001 drafts)
53 (run 'hg heads' to see heads, 'hg merge' to merge)
53 (run 'hg heads' to see heads, 'hg merge' to merge)
54 $ hg up
54 $ hg up
55 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
55 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
56 updated to "d9032adc8114: commit #5000"
56 updated to "d9032adc8114: commit #5000"
57 89 other heads for branch "default"
57 89 other heads for branch "default"
58
58
59 $ hg log --stat -r 0:3
59 $ hg log --stat -r 0:3
60 changeset: 0:9706f5af64f4
60 changeset: 0:9706f5af64f4
61 user: test
61 user: test
62 date: Thu Jan 01 00:00:00 1970 +0000
62 date: Thu Jan 01 00:00:00 1970 +0000
63 summary: initial commit
63 summary: initial commit
64
64
65 SPARSE-REVLOG-TEST-FILE | 10500 ++++++++++++++++++++++++++++++++++++++++++++++
65 SPARSE-REVLOG-TEST-FILE | 10500 ++++++++++++++++++++++++++++++++++++++++++++++
66 1 files changed, 10500 insertions(+), 0 deletions(-)
66 1 files changed, 10500 insertions(+), 0 deletions(-)
67
67
68 changeset: 1:724907deaa5e
68 changeset: 1:724907deaa5e
69 user: test
69 user: test
70 date: Thu Jan 01 00:00:00 1970 +0000
70 date: Thu Jan 01 00:00:00 1970 +0000
71 summary: commit #1
71 summary: commit #1
72
72
73 SPARSE-REVLOG-TEST-FILE | 1068 +++++++++++++++++++++++-----------------------
73 SPARSE-REVLOG-TEST-FILE | 1068 +++++++++++++++++++++++-----------------------
74 1 files changed, 534 insertions(+), 534 deletions(-)
74 1 files changed, 534 insertions(+), 534 deletions(-)
75
75
76 changeset: 2:62c41bce3e5d
76 changeset: 2:62c41bce3e5d
77 user: test
77 user: test
78 date: Thu Jan 01 00:00:00 1970 +0000
78 date: Thu Jan 01 00:00:00 1970 +0000
79 summary: commit #2
79 summary: commit #2
80
80
81 SPARSE-REVLOG-TEST-FILE | 1068 +++++++++++++++++++++++-----------------------
81 SPARSE-REVLOG-TEST-FILE | 1068 +++++++++++++++++++++++-----------------------
82 1 files changed, 534 insertions(+), 534 deletions(-)
82 1 files changed, 534 insertions(+), 534 deletions(-)
83
83
84 changeset: 3:348a9cbd6959
84 changeset: 3:348a9cbd6959
85 user: test
85 user: test
86 date: Thu Jan 01 00:00:00 1970 +0000
86 date: Thu Jan 01 00:00:00 1970 +0000
87 summary: commit #3
87 summary: commit #3
88
88
89 SPARSE-REVLOG-TEST-FILE | 1068 +++++++++++++++++++++++-----------------------
89 SPARSE-REVLOG-TEST-FILE | 1068 +++++++++++++++++++++++-----------------------
90 1 files changed, 534 insertions(+), 534 deletions(-)
90 1 files changed, 534 insertions(+), 534 deletions(-)
91
91
92
92
93 $ f -s .hg/store/data/*.d
93 $ f -s .hg/store/data/*.d
94 .hg/store/data/_s_p_a_r_s_e-_r_e_v_l_o_g-_t_e_s_t-_f_i_l_e.d: size=63327412
94 .hg/store/data/_s_p_a_r_s_e-_r_e_v_l_o_g-_t_e_s_t-_f_i_l_e.d: size=58616973
95 $ hg debugrevlog *
95 $ hg debugrevlog *
96 format : 1
96 format : 1
97 flags : generaldelta
97 flags : generaldelta
98
98
99 revisions : 5001
99 revisions : 5001
100 merges : 625 (12.50%)
100 merges : 625 (12.50%)
101 normal : 4376 (87.50%)
101 normal : 4376 (87.50%)
102 revisions : 5001
102 revisions : 5001
103 empty : 0 ( 0.00%)
103 empty : 0 ( 0.00%)
104 text : 0 (100.00%)
104 text : 0 (100.00%)
105 delta : 0 (100.00%)
105 delta : 0 (100.00%)
106 snapshot : 383 ( 7.66%)
106 snapshot : 383 ( 7.66%)
107 lvl-0 : 3 ( 0.06%)
107 lvl-0 : 3 ( 0.06%)
108 lvl-1 : 20 ( 0.40%)
108 lvl-1 : 18 ( 0.36%)
109 lvl-2 : 68 ( 1.36%)
109 lvl-2 : 62 ( 1.24%)
110 lvl-3 : 112 ( 2.24%)
110 lvl-3 : 108 ( 2.16%)
111 lvl-4 : 180 ( 3.60%)
111 lvl-4 : 191 ( 3.82%)
112 lvl-5 : 1 ( 0.02%)
112 deltas : 4618 (92.34%)
113 deltas : 4618 (92.34%)
113 revision size : 63327412
114 revision size : 58616973
114 snapshot : 9886710 (15.61%)
115 snapshot : 9247844 (15.78%)
115 lvl-0 : 603104 ( 0.95%)
116 lvl-0 : 539532 ( 0.92%)
116 lvl-1 : 1559991 ( 2.46%)
117 lvl-1 : 1467743 ( 2.50%)
117 lvl-2 : 2295592 ( 3.62%)
118 lvl-2 : 1873820 ( 3.20%)
118 lvl-3 : 2531199 ( 4.00%)
119 lvl-3 : 2326874 ( 3.97%)
119 lvl-4 : 2896824 ( 4.57%)
120 lvl-4 : 3029118 ( 5.17%)
120 deltas : 53440702 (84.39%)
121 lvl-5 : 10757 ( 0.02%)
122 deltas : 49369129 (84.22%)
121
123
122 chunks : 5001
124 chunks : 5001
123 0x78 (x) : 5001 (100.00%)
125 0x28 : 5001 (100.00%)
124 chunks size : 63327412
126 chunks size : 58616973
125 0x78 (x) : 63327412 (100.00%)
127 0x28 : 58616973 (100.00%)
126
128
127 avg chain length : 9
129 avg chain length : 9
128 max chain length : 15
130 max chain length : 15
129 max chain reach : 28248745
131 max chain reach : 27366701
130 compression ratio : 27
132 compression ratio : 29
131
133
132 uncompressed data size (min/max/avg) : 346468 / 346472 / 346471
134 uncompressed data size (min/max/avg) : 346468 / 346472 / 346471
133 full revision size (min/max/avg) : 201008 / 201050 / 201034
135 full revision size (min/max/avg) : 179288 / 180786 / 179844
134 inter-snapshot size (min/max/avg) : 11596 / 168150 / 24430
136 inter-snapshot size (min/max/avg) : 10757 / 169507 / 22916
135 level-1 (min/max/avg) : 16653 / 168150 / 77999
137 level-1 (min/max/avg) : 13905 / 169507 / 81541
136 level-2 (min/max/avg) : 12951 / 85595 / 33758
138 level-2 (min/max/avg) : 10887 / 83873 / 30222
137 level-3 (min/max/avg) : 11608 / 43029 / 22599
139 level-3 (min/max/avg) : 10911 / 43047 / 21545
138 level-4 (min/max/avg) : 11596 / 21632 / 16093
140 level-4 (min/max/avg) : 10838 / 21390 / 15859
139 delta size (min/max/avg) : 10649 / 107163 / 11572
141 level-5 (min/max/avg) : 10757 / 10757 / 10757
142 delta size (min/max/avg) : 9672 / 108072 / 10690
140
143
141 deltas against prev : 3910 (84.67%)
144 deltas against prev : 3906 (84.58%)
142 where prev = p1 : 3910 (100.00%)
145 where prev = p1 : 3906 (100.00%)
143 where prev = p2 : 0 ( 0.00%)
146 where prev = p2 : 0 ( 0.00%)
144 other : 0 ( 0.00%)
147 other : 0 ( 0.00%)
145 deltas against p1 : 648 (14.03%)
148 deltas against p1 : 649 (14.05%)
146 deltas against p2 : 60 ( 1.30%)
149 deltas against p2 : 63 ( 1.36%)
147 deltas against other : 0 ( 0.00%)
150 deltas against other : 0 ( 0.00%)
151
152 $ cd ..
General Comments 0
You need to be logged in to leave comments. Login now