cmd/utils, eth: relinquish GC cache to read cache in archive mode

This commit is contained in:
Péter Szilágyi
2019-02-05 12:49:59 +02:00
parent 85b3b1c8d6
commit d6225ab846
7 changed files with 24 additions and 17 deletions

View File

@ -1253,8 +1253,8 @@ func (bc *BlockChain) insertChain(chain types.Blocks, verifySeals bool) (int, []
stats.processed++
stats.usedGas += usedGas
cache, _ := bc.stateCache.TrieDB().Size()
stats.report(chain, it.index, cache)
dirty, _ := bc.stateCache.TrieDB().Size()
stats.report(chain, it.index, dirty)
}
// Any blocks remaining here? The only ones we care about are the future ones
if block != nil && err == consensus.ErrFutureBlock {