Skip to content

feat: short address for journal cold/warm check#2849

Merged
rakita merged 6 commits intomainfrom
rakita/journal_short_address_perf
Aug 6, 2025
Merged

feat: short address for journal cold/warm check#2849
rakita merged 6 commits intomainfrom
rakita/journal_short_address_perf

Conversation

@rakita
Copy link
Member

@rakita rakita commented Aug 5, 2025

Added optimisation for precompile short address access. This is an extension of #2846

Previously access list account was not loaded from database but inserted into the warm_accounts hashset. This made sense if the account from the access list is not accessed in execution. This PR switches this behaviour and always loads all access lists at the start to mark the warm.

@rakita rakita force-pushed the rakita/journal_short_address_perf branch from c100b21 to 1b832f7 Compare August 5, 2025 16:12
@codspeed-hq
Copy link

codspeed-hq bot commented Aug 5, 2025

CodSpeed Performance Report

Merging #2849 will improve performances by 3.01%

Comparing rakita/journal_short_address_perf (0823edd) with main (031aaee)

Summary

⚡ 1 improvements
✅ 170 untouched benchmarks

Benchmarks breakdown

Benchmark BASE HEAD Change
transfer_finalize 17.1 µs 16.6 µs +3.01%

@rakita rakita force-pushed the rakita/journal_short_address_perf branch from 278df4e to 0823edd Compare August 5, 2025 19:40
// Clear coinbase address warming for next tx
*warm_coinbase_address = None;
reset_preloaded_addresses(warm_preloaded_addresses, precompiles);
warm_addresses.clear_coinbase();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this doesn't clear precompiles anymore?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i guess it's always reset in set_precompile_addresses

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

set_precompile_addresses will reset it, and it is only called on spec_id change or if precompile address is empty.

@rakita rakita merged commit ac7d01f into main Aug 6, 2025
30 checks passed
@github-actions github-actions bot mentioned this pull request Aug 6, 2025
@DaniPopes
Copy link
Collaborator

lgtm

@rakita rakita deleted the rakita/journal_short_address_perf branch August 7, 2025 12:24
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