MCPcopy Create free account
hub / github.com/ElementsProject/elements / BlockToJsonVerboseWrite

Function BlockToJsonVerboseWrite

src/bench/rpc_blockchain.cpp:51–59  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

49BENCHMARK(BlockToJsonVerbose);
50
51static void BlockToJsonVerboseWrite(benchmark::Bench& bench)
52{
53 TestBlockAndIndex data;
54 auto univalue = blockToJSON(data.block, &data.blockindex, &data.blockindex, TxVerbosity::SHOW_DETAILS_AND_PREVOUT);
55 bench.run([&] {
56 auto str = univalue.write();
57 ankerl::nanobench::doNotOptimizeAway(str);
58 });
59}
60
61BENCHMARK(BlockToJsonVerboseWrite);

Callers

nothing calls this directly

Calls 4

blockToJSONFunction · 0.85
doNotOptimizeAwayFunction · 0.85
runMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected