Commit 05ec664
committed
Merge bitcoin/bitcoin#27666: wallet, bench: Move commonly used functions to their own file and fix a bug
7379a54 bench: Remove incorrect LoadWallet call in WalletBalance (Andrew Chow)
846b2fe tests: Move ADDRESS_BCRT1_UNSPENDABLE to wallet/test/util.h (Andrew Chow)
c61d3f0 tests, bench: Consolidate {Test,Bench}Un/LoadWallet helper (Andrew Chow)
Pull request description:
I have a few PRs and branches that use these two commits, probably makes sense to split them into a separate PR to be merged sooner.
The first commit contains some things that end up being commonly used in new wallet benchmarks. These are moved into `wallet_common.{h/cpp}`.
The second commit contains a bugfix for the wallet_balance benchmark where it calls `LoadWallet` in the wrong place. It's unnecessary to call that function in this benchmark. Although this does not cause any issues currently, it ends up causing issues in some PRs and branches that I'm working on.
ACKs for top commit:
Sjors:
utACK 7379a54
furszy:
ACK 7379a54
Tree-SHA512: 47773887a16c69ac7121c699d3446a8c399bd792a6a31714998b7b7a19fea179c6d3b29cb898b04397b2962c1b4120d57009352b8460b8283e188d4cb480c9baFile tree
5 files changed
+53
-63
lines changed- src
- bench
- wallet/test
5 files changed
+53
-63
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
| 18 | + | |
26 | 19 | | |
27 | 20 | | |
28 | 21 | | |
| |||
37 | 30 | | |
38 | 31 | | |
39 | 32 | | |
40 | | - | |
41 | 33 | | |
42 | 34 | | |
43 | 35 | | |
| |||
67 | 59 | | |
68 | 60 | | |
69 | 61 | | |
| 62 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
| 19 | + | |
45 | 20 | | |
46 | 21 | | |
47 | 22 | | |
| |||
66 | 41 | | |
67 | 42 | | |
68 | 43 | | |
69 | | - | |
| 44 | + | |
70 | 45 | | |
71 | 46 | | |
72 | 47 | | |
| |||
76 | 51 | | |
77 | 52 | | |
78 | 53 | | |
79 | | - | |
| 54 | + | |
80 | 55 | | |
81 | 56 | | |
82 | | - | |
| 57 | + | |
83 | 58 | | |
84 | 59 | | |
85 | 60 | | |
86 | | - | |
| 61 | + | |
87 | 62 | | |
88 | 63 | | |
89 | 64 | | |
| |||
96 | 71 | | |
97 | 72 | | |
98 | 73 | | |
| 74 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
| |||
45 | 46 | | |
46 | 47 | | |
47 | 48 | | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
48 | 79 | | |
49 | 80 | | |
50 | 81 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| |||
31 | 32 | | |
32 | 33 | | |
33 | 34 | | |
| 35 | + | |
| 36 | + | |
34 | 37 | | |
35 | 38 | | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
36 | 43 | | |
37 | 44 | | |
38 | 45 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | 45 | | |
66 | 46 | | |
67 | 47 | | |
| |||
845 | 825 | | |
846 | 826 | | |
847 | 827 | | |
| 828 | + | |
848 | 829 | | |
849 | 830 | | |
850 | | - | |
851 | | - | |
| 831 | + | |
| 832 | + | |
852 | 833 | | |
853 | 834 | | |
854 | 835 | | |
| |||
862 | 843 | | |
863 | 844 | | |
864 | 845 | | |
865 | | - | |
| 846 | + | |
866 | 847 | | |
867 | 848 | | |
868 | 849 | | |
| |||
885 | 866 | | |
886 | 867 | | |
887 | 868 | | |
888 | | - | |
| 869 | + | |
| 870 | + | |
| 871 | + | |
889 | 872 | | |
890 | 873 | | |
891 | 874 | | |
| |||
0 commit comments