You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -521,22 +507,23 @@ void CBlockPolicyEstimator::processBlock(unsigned int nBlockHeight,
521
507
// of unconfirmed txs to remove from tracking.
522
508
nBestSeenHeight = nBlockHeight;
523
509
524
-
//Clear the current block state and update unconfirmed circular buffer
510
+
//Update unconfirmed circular buffer
525
511
feeStats->ClearCurrent(nBlockHeight);
526
512
shortStats->ClearCurrent(nBlockHeight);
527
513
longStats->ClearCurrent(nBlockHeight);
528
514
515
+
// Decay all exponential averages
516
+
feeStats->UpdateMovingAverages();
517
+
shortStats->UpdateMovingAverages();
518
+
longStats->UpdateMovingAverages();
519
+
529
520
unsignedint countedTxs = 0;
530
-
//Repopulate the current block states
521
+
//Update averages with data points from current block
531
522
for (unsignedint i = 0; i < entries.size(); i++) {
532
523
if (processBlockTx(nBlockHeight, entries[i]))
533
524
countedTxs++;
534
525
}
535
526
536
-
// Update all exponential averages with the current block state
537
-
feeStats->UpdateMovingAverages();
538
-
shortStats->UpdateMovingAverages();
539
-
longStats->UpdateMovingAverages();
540
527
541
528
LogPrint(BCLog::ESTIMATEFEE, "Blockpolicy after updating estimates for %u of %u txs in block, since last block %u of %u tracked, new mempool map size %u\n",
0 commit comments