Commit 3d30409
perf: replace AccessListInspector with post-execution state-diff blocklist check
Replace the per-opcode AccessListInspector with a post-execution check
against ResultAndState.state (EvmState = HashMap<Address, Account>),
which already contains every address touched during EVM execution.
The AccessListInspector calls step() on every EVM opcode to build an
access list, solely used to check addresses against the blocklist.
Profiling shows this inspector overhead consumes ~52% of CPU time.
The EVM execution result already contains the same information in its
state diff, making the inspector redundant for this purpose.
This optimization works regardless of whether a blocklist is configured:
- Empty blocklist: skip inspector, skip blocklist check
- Non-empty blocklist: skip inspector, check state keys instead
When used_state_tracer is active (parallel builder), the inspector is
still attached for UsedStateEVMInspector, but blocklist checking still
uses the state diff instead of the access list.
Benchmark (builder-lab, 100 TPS contender, 60s profiling window):
| Metric | Before | After | Change |
|---------------------|----------|----------|--------|
| Block fill p50 | 98.8ms | 57.5ms | -42% |
| Block fill p95 | 144.9ms | 69.1ms | -52% |
| E2E latency p50 | 101ms | 59ms | -42% |
| E2E latency p95 | 147ms | 76ms | -48% |
| Avg bid value | 0.0041 | 0.0075 | +83% |
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent c66f845 commit 3d30409
1 file changed
Lines changed: 31 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1162 | 1162 | | |
1163 | 1163 | | |
1164 | 1164 | | |
| 1165 | + | |
| 1166 | + | |
| 1167 | + | |
| 1168 | + | |
| 1169 | + | |
| 1170 | + | |
| 1171 | + | |
| 1172 | + | |
| 1173 | + | |
| 1174 | + | |
| 1175 | + | |
| 1176 | + | |
| 1177 | + | |
| 1178 | + | |
| 1179 | + | |
| 1180 | + | |
| 1181 | + | |
| 1182 | + | |
| 1183 | + | |
| 1184 | + | |
| 1185 | + | |
| 1186 | + | |
| 1187 | + | |
| 1188 | + | |
| 1189 | + | |
| 1190 | + | |
| 1191 | + | |
| 1192 | + | |
| 1193 | + | |
1165 | 1194 | | |
1166 | 1195 | | |
1167 | 1196 | | |
| |||
1177 | 1206 | | |
1178 | 1207 | | |
1179 | 1208 | | |
1180 | | - | |
1181 | | - | |
| 1209 | + | |
| 1210 | + | |
1182 | 1211 | | |
1183 | 1212 | | |
1184 | 1213 | | |
| |||
0 commit comments