@@ -7,7 +7,7 @@ use bitcoin::{
7
7
absolute, constants, hashes:: Hash , key:: Secp256k1 , transaction, Amount , BlockHash , Network ,
8
8
OutPoint , ScriptBuf , Transaction , TxIn , TxOut ,
9
9
} ;
10
- use criterion:: { black_box , criterion_group, criterion_main, Criterion } ;
10
+ use criterion:: { criterion_group, criterion_main, Criterion } ;
11
11
use miniscript:: { Descriptor , DescriptorPublicKey } ;
12
12
use std:: sync:: Arc ;
13
13
@@ -126,7 +126,7 @@ fn run_filter_chain_unspents(tx_graph: &KeychainTxGraph, chain: &LocalChain, exp
126
126
127
127
pub fn many_conflicting_unconfirmed ( c : & mut Criterion ) {
128
128
const CONFLICTING_TX_COUNT : u32 = 2100 ;
129
- let ( tx_graph, chain) = black_box ( setup ( |tx_graph, _chain| {
129
+ let ( tx_graph, chain) = std :: hint :: black_box ( setup ( |tx_graph, _chain| {
130
130
let previous_output = add_ancestor_tx ( tx_graph, tip_block_id ( ) , 0 ) ;
131
131
// Create conflicting txs that spend from `previous_output`.
132
132
let spk_1 = spk_at_index ( & tx_graph. index , 1 ) ;
@@ -164,7 +164,7 @@ pub fn many_conflicting_unconfirmed(c: &mut Criterion) {
164
164
165
165
pub fn many_chained_unconfirmed ( c : & mut Criterion ) {
166
166
const TX_CHAIN_COUNT : u32 = 2100 ;
167
- let ( tx_graph, chain) = black_box ( setup ( |tx_graph, _chain| {
167
+ let ( tx_graph, chain) = std :: hint :: black_box ( setup ( |tx_graph, _chain| {
168
168
let mut previous_output = add_ancestor_tx ( tx_graph, tip_block_id ( ) , 0 ) ;
169
169
// Create a chain of unconfirmed txs where each subsequent tx spends the output of the
170
170
// previous one.
@@ -203,7 +203,7 @@ pub fn many_chained_unconfirmed(c: &mut Criterion) {
203
203
pub fn nested_conflicts ( c : & mut Criterion ) {
204
204
const CONFLICTS_PER_OUTPUT : usize = 3 ;
205
205
const GRAPH_DEPTH : usize = 7 ;
206
- let ( tx_graph, chain) = black_box ( setup ( |tx_graph, _chain| {
206
+ let ( tx_graph, chain) = std :: hint :: black_box ( setup ( |tx_graph, _chain| {
207
207
let mut prev_ops = core:: iter:: once ( add_ancestor_tx ( tx_graph, tip_block_id ( ) , 0 ) )
208
208
. collect :: < Vec < OutPoint > > ( ) ;
209
209
for depth in 1 ..GRAPH_DEPTH {
0 commit comments