Skip to content

Conversation

@edg-l
Copy link
Contributor

@edg-l edg-l commented Jan 5, 2026

Motivation

Description

Checklist

  • Updated STORE_SCHEMA_VERSION (crates/storage/lib.rs) if the PR includes breaking changes to the Store requiring a re-sync.

Closes #issue_number

@github-actions github-actions bot added L1 Ethereum client performance Block execution throughput and performance in general labels Jan 5, 2026
@github-actions
Copy link

github-actions bot commented Jan 5, 2026

Lines of code report

Total lines added: 6
Total lines removed: 0
Total lines changed: 6

Detailed view
+------------------------------------------------------------------------+-------+------+
| File                                                                   | Lines | Diff |
+------------------------------------------------------------------------+-------+------+
| ethrex/crates/common/types/account.rs                                  | 325   | +2   |
+------------------------------------------------------------------------+-------+------+
| ethrex/crates/vm/levm/src/opcode_handlers/stack_memory_storage_flow.rs | 254   | +4   |
+------------------------------------------------------------------------+-------+------+

@github-actions
Copy link

github-actions bot commented Jan 5, 2026

Benchmark Results Comparison

No significant difference was registered for any benchmark run.

Detailed Results

Benchmark Results: BubbleSort

Command Mean [s] Min [s] Max [s] Relative
main_revm_BubbleSort 2.964 ± 0.024 2.933 3.006 1.00 ± 0.01
main_levm_BubbleSort 2.998 ± 0.014 2.973 3.021 1.01 ± 0.01
pr_revm_BubbleSort 2.956 ± 0.014 2.935 2.973 1.00
pr_levm_BubbleSort 3.029 ± 0.036 2.971 3.090 1.02 ± 0.01

Benchmark Results: ERC20Approval

Command Mean [ms] Min [ms] Max [ms] Relative
main_revm_ERC20Approval 986.2 ± 9.0 971.9 1001.7 1.00
main_levm_ERC20Approval 1047.1 ± 12.5 1034.4 1075.8 1.06 ± 0.02
pr_revm_ERC20Approval 1006.4 ± 6.0 1000.1 1017.5 1.02 ± 0.01
pr_levm_ERC20Approval 1051.5 ± 16.3 1036.8 1081.5 1.07 ± 0.02

Benchmark Results: ERC20Mint

Command Mean [ms] Min [ms] Max [ms] Relative
main_revm_ERC20Mint 132.0 ± 2.4 129.6 138.3 1.00
main_levm_ERC20Mint 155.7 ± 1.7 154.2 159.2 1.18 ± 0.03
pr_revm_ERC20Mint 134.9 ± 0.7 133.8 136.0 1.02 ± 0.02
pr_levm_ERC20Mint 155.6 ± 1.2 154.6 158.0 1.18 ± 0.02

Benchmark Results: ERC20Transfer

Command Mean [ms] Min [ms] Max [ms] Relative
main_revm_ERC20Transfer 232.5 ± 3.3 230.0 241.1 1.00
main_levm_ERC20Transfer 267.0 ± 2.7 263.2 273.1 1.15 ± 0.02
pr_revm_ERC20Transfer 239.4 ± 13.4 233.7 277.3 1.03 ± 0.06
pr_levm_ERC20Transfer 265.7 ± 2.2 262.4 269.3 1.14 ± 0.02

Benchmark Results: Factorial

Command Mean [ms] Min [ms] Max [ms] Relative
main_revm_Factorial 225.3 ± 1.5 222.6 227.8 1.00
main_levm_Factorial 256.3 ± 1.8 254.9 259.6 1.14 ± 0.01
pr_revm_Factorial 226.1 ± 1.6 224.2 229.1 1.00 ± 0.01
pr_levm_Factorial 257.1 ± 3.2 255.3 266.1 1.14 ± 0.02

Benchmark Results: FactorialRecursive

Command Mean [s] Min [s] Max [s] Relative
main_revm_FactorialRecursive 1.625 ± 0.039 1.530 1.675 1.02 ± 0.04
main_levm_FactorialRecursive 8.456 ± 0.028 8.410 8.492 5.30 ± 0.13
pr_revm_FactorialRecursive 1.596 ± 0.039 1.539 1.643 1.00
pr_levm_FactorialRecursive 8.516 ± 0.057 8.448 8.654 5.34 ± 0.14

Benchmark Results: Fibonacci

Command Mean [ms] Min [ms] Max [ms] Relative
main_revm_Fibonacci 205.2 ± 0.5 204.6 206.1 1.00
main_levm_Fibonacci 232.6 ± 3.2 225.3 235.8 1.13 ± 0.02
pr_revm_Fibonacci 205.2 ± 1.6 203.9 209.3 1.00 ± 0.01
pr_levm_Fibonacci 240.9 ± 13.7 229.7 278.9 1.17 ± 0.07

Benchmark Results: FibonacciRecursive

Command Mean [ms] Min [ms] Max [ms] Relative
main_revm_FibonacciRecursive 852.7 ± 15.9 837.6 887.8 1.23 ± 0.05
main_levm_FibonacciRecursive 709.1 ± 31.5 646.4 739.2 1.02 ± 0.06
pr_revm_FibonacciRecursive 844.8 ± 7.2 835.9 859.5 1.22 ± 0.04
pr_levm_FibonacciRecursive 694.9 ± 24.1 648.8 714.5 1.00

Benchmark Results: ManyHashes

Command Mean [ms] Min [ms] Max [ms] Relative
main_revm_ManyHashes 8.4 ± 0.1 8.4 8.5 1.00 ± 0.01
main_levm_ManyHashes 9.2 ± 0.1 9.0 9.4 1.09 ± 0.02
pr_revm_ManyHashes 8.4 ± 0.1 8.3 8.6 1.00
pr_levm_ManyHashes 9.1 ± 0.1 8.9 9.2 1.08 ± 0.01

Benchmark Results: MstoreBench

Command Mean [ms] Min [ms] Max [ms] Relative
main_revm_MstoreBench 261.3 ± 0.8 260.0 262.7 1.08 ± 0.01
main_levm_MstoreBench 242.4 ± 1.9 239.1 245.7 1.00
pr_revm_MstoreBench 260.8 ± 4.7 258.0 274.0 1.08 ± 0.02
pr_levm_MstoreBench 243.9 ± 2.5 240.8 249.4 1.01 ± 0.01

Benchmark Results: Push

Command Mean [ms] Min [ms] Max [ms] Relative
main_revm_Push 288.3 ± 1.0 286.9 289.7 1.00
main_levm_Push 306.7 ± 4.5 302.8 318.0 1.06 ± 0.02
pr_revm_Push 288.3 ± 1.2 286.8 290.7 1.00 ± 0.01
pr_levm_Push 327.2 ± 1.4 324.8 329.4 1.13 ± 0.01

Benchmark Results: SstoreBench_no_opt

Command Mean [ms] Min [ms] Max [ms] Relative
main_revm_SstoreBench_no_opt 166.6 ± 5.1 159.6 171.9 1.80 ± 0.13
main_levm_SstoreBench_no_opt 92.4 ± 6.0 88.5 108.8 1.00
pr_revm_SstoreBench_no_opt 166.3 ± 8.0 159.4 184.6 1.80 ± 0.15
pr_levm_SstoreBench_no_opt 94.0 ± 4.3 89.0 100.8 1.02 ± 0.08

@edg-l edg-l force-pushed the perf_bitmap_jumps branch from 3c394cc to e4cb60d Compare January 5, 2026 14:27
@github-actions
Copy link

github-actions bot commented Jan 5, 2026

Benchmark Block Execution Results Comparison Against Main

Command Mean [s] Min [s] Max [s] Relative
base 64.420 ± 0.436 64.043 65.148 1.01 ± 0.01
head 64.038 ± 0.402 63.328 64.717 1.00

@edg-l edg-l marked this pull request as ready for review January 7, 2026 08:22
@edg-l edg-l requested a review from a team as a code owner January 7, 2026 08:22
@iovoid iovoid changed the title perf(l1): change jump_targets to a bitmap perf(l1)!: change jump_targets to a bitmap Jan 7, 2026
@github-actions github-actions bot removed performance Block execution throughput and performance in general L1 Ethereum client labels Jan 7, 2026
Comment on lines 33 to 35
// The valid addresses are 32-bit because, despite EIP-3860 restricting initcode size,
// this does not apply to previous forks. This is tested in the EEST tests, which would
// panic in debug mode.
Copy link
Contributor

Choose a reason for hiding this comment

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

This comment should be updated, since it's about the specifics of the old implementation

let bytes_size = size_of::<Bytes>();
let vec_size = size_of::<Vec<u32>>() + self.jump_targets.len() * size_of::<u32>();
hash_size + bytes_size + vec_size
let bitmap_size = size_of::<Vec<u64>>() + self.jump_targets.len() * size_of::<u64>();
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe use std::mem::size_of_val like in encode_code (which should probably be calling this function instead of calculating this).

@edg-l
Copy link
Contributor Author

edg-l commented Jan 8, 2026

Seeing the eest benches, this doesn't improve performance, so im closing it

@edg-l edg-l closed this Jan 8, 2026
@github-project-automation github-project-automation bot moved this from Todo to Done in ethrex_performance Jan 8, 2026
@github-project-automation github-project-automation bot moved this to Done in ethrex_l1 Jan 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done
Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants