@@ -50,6 +50,7 @@ import (
5050 "github.com/erigontech/erigon/db/kv/order"
5151 "github.com/erigontech/erigon/db/kv/rawdbv3"
5252 "github.com/erigontech/erigon/db/kv/stream"
53+ "github.com/erigontech/erigon/db/seg"
5354 "github.com/erigontech/erigon/db/state/changeset"
5455 "github.com/erigontech/erigon/db/state/statecfg"
5556 "github.com/erigontech/erigon/db/version"
@@ -669,13 +670,15 @@ func (a *Aggregator) Files() []string {
669670 return ac .AllFiles ().Fullpaths ()
670671}
671672func (a * Aggregator ) LS () {
673+ var stats seg.Stats
672674 doLS := func (dirtyFiles * btree.BTreeG [* FilesItem ]) {
673675 dirtyFiles .Walk (func (items []* FilesItem ) bool {
674676 for _ , item := range items {
675677 if item .decompressor == nil {
676678 continue
677679 }
678- a .logger .Info ("[agg] " , "f" , item .decompressor .FileName (), "words" , item .decompressor .Count ())
680+ a .logger .Info ("[agg] " , "f" , item .decompressor .FileName (), "words" , item .decompressor .Count (), "dictOnDisk" , common .ByteCount (item .decompressor .SerializedTotalDictSize ()), "dictMem" , common .ByteCount (item .decompressor .DictMemSize ()))
681+ stats .Add (item .decompressor )
679682 }
680683 return true
681684 })
@@ -691,6 +694,7 @@ func (a *Aggregator) LS() {
691694 for _ , d := range a .iis {
692695 doLS (d .dirtyFiles )
693696 }
697+ a .logger .Info ("[agg] total" , "words" , stats .Words , "dictOnDisk" , common .ByteCount (stats .Dict ), "dictMem" , common .ByteCount (stats .DictMem ))
694698}
695699
696700func (a * Aggregator ) WaitForBuildAndMerge (ctx context.Context ) chan struct {} {
0 commit comments