 |
Bitcoin Core
22.99.0
P2P Digital Currency
|
Go to the documentation of this file.
20 static const auto testing_setup = MakeNoLogFileContext<>();
31 const std::optional<CMutableTransaction> mtx = ConsumeDeserializable<CMutableTransaction>(fuzzed_data_provider);
42 std::vector<CTxMemPoolEntry> mempool_entries;
44 const std::optional<CMutableTransaction> mtx = ConsumeDeserializable<CMutableTransaction>(fuzzed_data_provider);
51 std::vector<const CTxMemPoolEntry*> ptrs;
52 ptrs.reserve(mempool_entries.size());
54 ptrs.push_back(&mempool_entry);
73 CAutoFile fuzzed_auto_file = fuzzed_auto_file_provider.
open();
74 block_policy_estimator.
Write(fuzzed_auto_file);
75 block_policy_estimator.
Read(fuzzed_auto_file);
uint256 ConsumeUInt256(FuzzedDataProvider &fuzzed_data_provider) noexcept
bool Read(CAutoFile &filein) EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator)
Read estimation data from a file.
FUZZ_TARGET_INIT(policy_estimator, initialize_policy_estimator)
CFeeRate estimateFee(int confTarget) const EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator)
DEPRECATED.
void processBlock(unsigned int nBlockHeight, std::vector< const CTxMemPoolEntry * > &entries) EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator)
Process all the transactions that have been included in a block.
T PickValueInArray(const T(&array)[size])
CFeeRate estimateSmartFee(int confTarget, FeeCalculation *feeCalc, bool conservative) const EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator)
Estimate feerate needed to get be included in a block within confTarget blocks.
bool removeTx(uint256 hash, bool inBlock) EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator)
Remove a transaction from the mempool tracking stats.
The basic transaction that is broadcasted on the network and contained in blocks.
Non-refcounted RAII wrapper for FILE*.
size_t CallOneOf(FuzzedDataProvider &fuzzed_data_provider, Callables... callables)
CTxMemPoolEntry ConsumeTxMemPoolEntry(FuzzedDataProvider &fuzzed_data_provider, const CTransaction &tx) noexcept
#define LIMITED_WHILE(condition, limit)
Can be used to limit a theoretically unbounded loop.
bool Write(CAutoFile &fileout) const EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator)
Write estimation data to a file.
CFeeRate estimateRawFee(int confTarget, double successThreshold, FeeEstimateHorizon horizon, EstimationResult *result=nullptr) const EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator)
Return a specific fee estimate calculation with a given success threshold and time horizon,...
FuzzedAutoFileProvider ConsumeAutoFile(FuzzedDataProvider &fuzzed_data_provider) noexcept
void initialize_policy_estimator()
unsigned int HighestTargetTracked(FeeEstimateHorizon horizon) const EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator)
Calculation of highest target that estimates are tracked for.
void FlushUnconfirmed() EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator)
Empty mempool transactions on shutdown to record failure to confirm for txs still in mempool.
static constexpr auto ALL_FEE_ESTIMATE_HORIZONS
void processTransaction(const CTxMemPoolEntry &entry, bool validFeeEstimate) EXCLUSIVE_LOCKS_REQUIRED(!m_cs_fee_estimator)
Process a transaction accepted to the mempool.