mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-06-04 18:22:57 +02:00
clusterlin: randomize various decisions in SFL (feature)
This introduces a local RNG inside the SFL state, which is used to randomize various decisions inside the algorithm, in order to make it hard to create pathological clusters which predictably have bad performance. The decisions being randomized are: * When deciding what chunk to attempt to split, the queue order is randomized. * When deciding which dependency to split on, a uniformly random one is chosen among those with higher top feerate than bottom feerate within the chosen chunk. * When deciding which chunks to merge, a uniformly random one among those with the higher feerate difference is picked. * When merging two chunks, a uniformly random dependency between them is now activated. * When making the state topological, the queue of chunks to process is randomized.
This commit is contained in:
@@ -1021,7 +1021,7 @@ FUZZ_TARGET(clusterlin_sfl)
|
||||
|
||||
// Initialize SFL state.
|
||||
if (make_connected) MakeConnected(depgraph);
|
||||
SpanningForestState sfl(depgraph);
|
||||
SpanningForestState sfl(depgraph, rng.rand64());
|
||||
|
||||
// Function to test the state.
|
||||
std::vector<FeeFrac> last_diagram;
|
||||
|
||||
Reference in New Issue
Block a user