14#include <test/util/setup_common.h>
15#include <validation.h>
31 const auto testing_setup{
39 const auto success{chainman.m_blockman.ReadBlockFromDisk(block, pos)};
45 const auto testing_setup{
49 std::vector<uint8_t> block_data;
54 chainman.m_blockman.ReadRawBlockFromDisk(block_data, pos)};
Provides an interface for creating and interacting with one or two chainstates: an IBD chainstate gen...
node::BlockManager m_blockman
A single BlockManager instance is shared across each constructed chainstate to avoid duplicating bloc...
Double ended buffer combining vector and stream-like interfaces.
Main entry point to nanobench's benchmarking facility.
Bench & run(char const *benchmarkName, Op &&op)
Repeatedly calls op() based on the configuration, and performs measurements.
bool WriteUndoDataForBlock(const CBlockUndo &blockundo, BlockValidationState &state, CBlockIndex &block) EXCLUSIVE_LOCKS_REQUIRED(FlatFilePos SaveBlockToDisk(const CBlock &block, int nHeight)
Store block on disk and update block file statistics.
const std::vector< uint8_t > block413567
static void ReadRawBlockFromDiskBench(benchmark::Bench &bench)
BENCHMARK(ReadBlockFromDiskBench)
static void ReadBlockFromDiskBench(benchmark::Bench &bench)
static FlatFilePos WriteBlockToDisk(ChainstateManager &chainman)