aboutsummaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorPéter Szilágyi <peterke@gmail.com>2016-10-19 22:17:42 +0800
committerPéter Szilágyi <peterke@gmail.com>2016-10-19 22:31:19 +0800
commit88a593d559d26a91b64178094728fd9ca7c25a2c (patch)
tree6ae827ef8a6b62c0fc9e14c8e72a44b47fba5c82 /core
parent5d9bb0a050df0e58ed1073ef92f45676380ac26e (diff)
downloadgo-tangerine-88a593d559d26a91b64178094728fd9ca7c25a2c.tar
go-tangerine-88a593d559d26a91b64178094728fd9ca7c25a2c.tar.gz
go-tangerine-88a593d559d26a91b64178094728fd9ca7c25a2c.tar.bz2
go-tangerine-88a593d559d26a91b64178094728fd9ca7c25a2c.tar.lz
go-tangerine-88a593d559d26a91b64178094728fd9ca7c25a2c.tar.xz
go-tangerine-88a593d559d26a91b64178094728fd9ca7c25a2c.tar.zst
go-tangerine-88a593d559d26a91b64178094728fd9ca7c25a2c.zip
cmd/geth, trie: report on trie cache unloads, also add debug log
Diffstat (limited to 'core')
-rw-r--r--core/state/statedb.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/core/state/statedb.go b/core/state/statedb.go
index 6a24d2865..ae106e03b 100644
--- a/core/state/statedb.go
+++ b/core/state/statedb.go
@@ -564,6 +564,8 @@ func (s *StateDB) Commit() (root common.Hash, err error) {
func (s *StateDB) CommitBatch() (root common.Hash, batch ethdb.Batch) {
batch = s.db.NewBatch()
root, _ = s.commit(batch)
+
+ glog.V(logger.Debug).Infof("Trie cache stats: %d misses, %d unloads", trie.CacheMisses(), trie.CacheUnloads())
return root, batch
}