Skip to content

core: log detailed statistics for slow block - #32812

Merged
fjl merged 15 commits into
ethereum:masterfrom
rjl493456442:verbose-log
Dec 2, 2025
Merged

core: log detailed statistics for slow block#32812
fjl merged 15 commits into
ethereum:masterfrom
rjl493456442:verbose-log

Conversation

@rjl493456442

@rjl493456442 rjl493456442 commented Sep 30, 2025

Copy link
Copy Markdown
Member

This PR introduces a new debug feature, logging the slow blocks with detailed
performance statistics, such as state read, EVM execution and so on.

Notably, the detailed performance statistics of slow blocks won't be logged
during the sync to not overwhelm users. Specifically, the statistics are only
logged if there is a single block processed.

Example output

########## SLOW BLOCK #########
Block: 23537063 (0xa7f878611c2dd27f245fc41107d12ebcf06b4e289f1d6acf44d49a169554ee09) txs: 248, mgasps: 202.99

EVM execution: 63.295ms
Validation: 1.130ms
Account read: 6.634ms(648)
Storage read: 17.391ms(1434)
State hash: 6.722ms
DB commit: 3.260ms
Block write: 1.954ms
Total: 99.094ms

State read cache: account (hit: 622, miss: 26), storage (hit: 1325, miss: 109)
##############################

@rjl493456442 rjl493456442 added this to the 1.16.8 milestone Nov 4, 2025
@fjl fjl removed the status:triage label Dec 2, 2025
@fjl fjl changed the title core, cmd, eth: log detailed statistics for slow block core: log detailed statistics for slow block Dec 2, 2025
@fjl
fjl merged commit 042c47c into ethereum:master Dec 2, 2025
8 of 9 checks passed
weiihann pushed a commit to weiihann/go-ethereum that referenced this pull request Jan 14, 2026
This PR introduces a new debug feature, logging the slow blocks with
detailed performance statistics, such as state read, EVM execution and
so on.

Notably, the detailed performance statistics of slow blocks won't be
logged during the sync to not overwhelm users. Specifically, the statistics
are only logged if there is a single block processed.

Example output

```
########## SLOW BLOCK #########
Block: 23537063 (0xa7f878611c2dd27f245fc41107d12ebcf06b4e289f1d6acf44d49a169554ee09) txs: 248, mgasps: 202.99

EVM execution: 63.295ms
Validation: 1.130ms
Account read: 6.634ms(648)
Storage read: 17.391ms(1434)
State hash: 6.722ms
DB commit: 3.260ms
Block write: 1.954ms
Total: 99.094ms

State read cache: account (hit: 622, miss: 26), storage (hit: 1325, miss: 109)
##############################
```
gballet pushed a commit to BZO95/go-ethereum that referenced this pull request May 21, 2026
This PR introduces a new debug feature, logging the slow blocks with
detailed performance statistics, such as state read, EVM execution and
so on.

Notably, the detailed performance statistics of slow blocks won't be
logged during the sync to not overwhelm users. Specifically, the statistics
are only logged if there is a single block processed.

Example output

```
########## SLOW BLOCK #########
Block: 23537063 (0xa7f878611c2dd27f245fc41107d12ebcf06b4e289f1d6acf44d49a169554ee09) txs: 248, mgasps: 202.99

EVM execution: 63.295ms
Validation: 1.130ms
Account read: 6.634ms(648)
Storage read: 17.391ms(1434)
State hash: 6.722ms
DB commit: 3.260ms
Block write: 1.954ms
Total: 99.094ms

State read cache: account (hit: 622, miss: 26), storage (hit: 1325, miss: 109)
##############################
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants