18 const auto testing_setup{MakeNoLogFileContext<const BasicTestingSetup>(
ChainType::REGTEST)};
20 const size_t file_size = 200;
21 uint8_t
data[file_size] = {0};
22 data[file_size - 1] = 1;
24 file.seek(0, SEEK_SET);
27 bench.
setup([&] { bf.SetPos(0); })
28 .run([&] { bf.FindByte(std::byte(1)); });
30 assert(file.fclose() == 0);
Non-refcounted RAII wrapper for FILE*.
Wrapper around an AutoFile& that implements a ring buffer to deserialize from.
Main entry point to nanobench's benchmarking facility.
detail::SetupRunner< SetupOp > setup(SetupOp setupOp)
Configure an untimed setup step per epoch (forces single-iteration epochs).
FILE * fopen(const fs::path &p, const char *mode)
static void FindByte(benchmark::Bench &bench)