Changeset View
Changeset View
Standalone View
Standalone View
src/bench/block_assemble.cpp
Show All 36 Lines | for (size_t b = 0; b < NUM_BLOCKS; ++b) { | ||||
} | } | ||||
} | } | ||||
{ | { | ||||
// Required for ::AcceptToMemoryPool. | // Required for ::AcceptToMemoryPool. | ||||
LOCK(::cs_main); | LOCK(::cs_main); | ||||
for (const auto &txr : txs) { | for (const auto &txr : txs) { | ||||
CValidationState vstate; | TxValidationState vstate; | ||||
bool ret{::AcceptToMemoryPool(config, ::g_mempool, vstate, txr, | bool ret{::AcceptToMemoryPool(config, ::g_mempool, vstate, txr, | ||||
false /* bypass_limits */, | false /* bypass_limits */, | ||||
/* nAbsurdFee */ Amount::zero())}; | /* nAbsurdFee */ Amount::zero())}; | ||||
assert(ret); | assert(ret); | ||||
} | } | ||||
} | } | ||||
while (state.KeepRunning()) { | while (state.KeepRunning()) { | ||||
PrepareBlock(config, SCRIPT_PUB); | PrepareBlock(config, SCRIPT_PUB); | ||||
} | } | ||||
} | } | ||||
BENCHMARK(AssembleBlock, 700); | BENCHMARK(AssembleBlock, 700); |