CMakeLists.txt raw
1 # Copyright (c) 2023-present The Bitcoin Core developers
2 # Distributed under the MIT software license, see the accompanying
3 # file COPYING or https://opensource.org/license/mit/.
4
5 add_executable(bench_bitcoin
6 bench_bitcoin.cpp
7 bench.cpp
8 nanobench.cpp
9 # Benchmarks:
10 addrman.cpp
11 base58.cpp
12 bech32.cpp
13 bip324_ecdh.cpp
14 block_assemble.cpp
15 blockencodings.cpp
16 ccoins_caching.cpp
17 chacha20.cpp
18 checkblock.cpp
19 checkblockindex.cpp
20 checkqueue.cpp
21 cluster_linearize.cpp
22 connectblock.cpp
23 crypto_hash.cpp
24 descriptors.cpp
25 disconnected_transactions.cpp
26 duplicate_inputs.cpp
27 ellswift.cpp
28 examples.cpp
29 gcs_filter.cpp
30 hashpadding.cpp
31 index_blockfilter.cpp
32 load_external.cpp
33 lockedpool.cpp
34 logging.cpp
35 mempool_ephemeral_spends.cpp
36 mempool_eviction.cpp
37 mempool_stress.cpp
38 merkle_root.cpp
39 obfuscation.cpp
40 parse_hex.cpp
41 peer_eviction.cpp
42 poly1305.cpp
43 pool.cpp
44 prevector.cpp
45 random.cpp
46 readwriteblock.cpp
47 rollingbloom.cpp
48 rpc_blockchain.cpp
49 rpc_mempool.cpp
50 sign_transaction.cpp
51 streams_findbyte.cpp
52 strencodings.cpp
53 txgraph.cpp
54 txorphanage.cpp
55 util_time.cpp
56 verify_script.cpp
57 )
58
59 add_windows_application_manifest(bench_bitcoin)
60
61 include(TargetDataSources)
62 target_raw_data_sources(bench_bitcoin NAMESPACE benchmark::data
63 data/block413567.raw
64 )
65
66 target_link_libraries(bench_bitcoin
67 core_interface
68 test_util
69 bitcoin_node
70 Boost::headers
71 )
72
73 if(WITH_EMBEDDED_ASMAP)
74 target_sources(bench_bitcoin PRIVATE asmap.cpp)
75 endif()
76
77 if(ENABLE_WALLET)
78 target_sources(bench_bitcoin
79 PRIVATE
80 coin_selection.cpp
81 wallet_balance.cpp
82 wallet_create.cpp
83 wallet_create_tx.cpp
84 wallet_encrypt.cpp
85 wallet_loading.cpp
86 wallet_ismine.cpp
87 wallet_migration.cpp
88 )
89 target_link_libraries(bench_bitcoin bitcoin_wallet)
90 endif()
91
92 install_binary_component(bench_bitcoin INTERNAL)
93