diff options
author | Péter Szilágyi <peterke@gmail.com> | 2016-10-19 22:35:58 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-10-19 22:35:58 +0800 |
commit | f2ae2f7eef1e3e15b9e6f81e2b5895e2d20d12bc (patch) | |
tree | 6ae827ef8a6b62c0fc9e14c8e72a44b47fba5c82 /core | |
parent | 5d9bb0a050df0e58ed1073ef92f45676380ac26e (diff) | |
parent | 88a593d559d26a91b64178094728fd9ca7c25a2c (diff) | |
download | dexon-f2ae2f7eef1e3e15b9e6f81e2b5895e2d20d12bc.tar.gz dexon-f2ae2f7eef1e3e15b9e6f81e2b5895e2d20d12bc.tar.zst dexon-f2ae2f7eef1e3e15b9e6f81e2b5895e2d20d12bc.zip |
Merge pull request #3176 from karalabe/trie-stats-report
cmd/geth, trie: report on trie cache unloads, also add debug log
Diffstat (limited to 'core')
-rw-r--r-- | core/state/statedb.go | 2 |
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 } |