Algorithm weightings for work contribution to chain

This commit is contained in:
myriadcoin
2014-04-07 18:39:15 +02:00
parent 4bbebad4f3
commit 34abdc7317
4 changed files with 14 additions and 9 deletions
+2 -1
View File
@@ -2089,10 +2089,11 @@ bool SetBestChain(CValidationState &state, CBlockIndex* pindexNew)
nBestChainWork = pindexNew->nChainWork;
nTimeBestReceived = GetTime();
nTransactionsUpdated++;
printf("SetBestChain: new best=%s height=%d pow_algo=%d log2_work=%.8g tx=%lu date=%s progress=%f\n",
printf("SetBestChain: new best=%s height=%d pow_algo=%d block_work=%s log2_work=%.8g tx=%lu date=%s progress=%f\n",
hashBestChain.ToString().c_str(),
nBestHeight,
pindexNew->GetAlgo(),
pindexNew->GetBlockWorkAdjusted().ToString().c_str(),
log(nBestChainWork.getdouble())/log(2.0),
(unsigned long)pindexNew->nChainTx,
DateTimeStrFormat("%Y-%m-%d %H:%M:%S", pindexBest->GetBlockTime()).c_str(),