Skip to content

Commit

Permalink
print lru stats after exec stage (#11601)
Browse files Browse the repository at this point in the history
  • Loading branch information
AskAlexSharov authored Aug 15, 2024
1 parent f6a39a5 commit 4b5373e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cmd/state/exec3/state.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@ func NewWorker(lock sync.Locker, logger log.Logger, ctx context.Context, backgro
return w
}

func (rw *Worker) LogLRUStats() { rw.evm.JumpDestCache.LogStats() }

func (rw *Worker) ResetState(rs *state.StateV3, accumulator *shards.Accumulator) {
rw.rs = rs
if rw.background {
Expand Down
1 change: 1 addition & 0 deletions eth/stagedsync/exec3.go
Original file line number Diff line number Diff line change
Expand Up @@ -385,6 +385,7 @@ func ExecV3(ctx context.Context,
applyWorker = cfg.applyWorkerMining
}
applyWorker.ResetState(rs, accumulator)
defer applyWorker.LogLRUStats()

commitThreshold := batchSize.Bytes()
progress := NewProgress(blockNum, commitThreshold, workerCount, false, execStage.LogPrefix(), logger)
Expand Down

0 comments on commit 4b5373e

Please sign in to comment.