Skip to content

fix(levm): remove logs from transaction revert#2483

Merged
JulianVentura merged 2 commits into
mainfrom
fix/levm-logs-on-reverts
Apr 16, 2025
Merged

fix(levm): remove logs from transaction revert#2483
JulianVentura merged 2 commits into
mainfrom
fix/levm-logs-on-reverts

Conversation

@JulianVentura

@JulianVentura JulianVentura commented Apr 16, 2025

Copy link
Copy Markdown
Contributor

Description

This PR removes logs from the ExecutionReport when a transaction reverts.
With this fix, LEVM no longer breaks at block 80k while syncing on Holesky testnet.

@github-actions

Copy link
Copy Markdown

Lines of code report

Total lines added: 25
Total lines removed: 100
Total lines changed: 125

Detailed view
+------------------------------------------------+-------+------+
| File                                           | Lines | Diff |
+------------------------------------------------+-------+------+
| ethrex/crates/blockchain/payload.rs            | 551   | +3   |
+------------------------------------------------+-------+------+
| ethrex/crates/l2/sequencer/block_producer.rs   | 106   | -5   |
+------------------------------------------------+-------+------+
| ethrex/crates/l2/sequencer/errors.rs           | 170   | -11  |
+------------------------------------------------+-------+------+
| ethrex/crates/l2/sequencer/l1_committer.rs     | 405   | +22  |
+------------------------------------------------+-------+------+
| ethrex/crates/l2/sequencer/state_diff.rs       | 410   | -56  |
+------------------------------------------------+-------+------+
| ethrex/crates/l2/utils/error.rs                | 17    | -5   |
+------------------------------------------------+-------+------+
| ethrex/crates/l2/utils/mod.rs                  | 5     | -1   |
+------------------------------------------------+-------+------+
| ethrex/crates/networking/rpc/engine/payload.rs | 683   | -1   |
+------------------------------------------------+-------+------+
| ethrex/crates/vm/backends/mod.rs               | 241   | -1   |
+------------------------------------------------+-------+------+
| ethrex/crates/vm/backends/revm/db.rs           | 206   | -19  |
+------------------------------------------------+-------+------+
| ethrex/crates/vm/levm/src/vm.rs                | 439   | -1   |
+------------------------------------------------+-------+------+

@github-actions

github-actions Bot commented Apr 16, 2025

Copy link
Copy Markdown

Benchmark Results Comparison

PR Results

Benchmark Results: Factorial

Command Mean [ms] Min [ms] Max [ms] Relative
revm_Factorial 243.0 ± 5.7 237.8 258.9 1.00
levm_Factorial 810.6 ± 25.2 789.6 871.3 3.34 ± 0.13

Benchmark Results: Factorial - Recursive

Command Mean [s] Min [s] Max [s] Relative
revm_FactorialRecursive 1.411 ± 0.091 1.308 1.553 1.00
levm_FactorialRecursive 13.975 ± 0.034 13.932 14.027 9.91 ± 0.64

Benchmark Results: Fibonacci

Command Mean [ms] Min [ms] Max [ms] Relative
revm_Fibonacci 219.6 ± 5.6 215.3 234.3 1.00
levm_Fibonacci 781.2 ± 6.2 769.5 789.5 3.56 ± 0.09

Benchmark Results: ManyHashes

Command Mean [ms] Min [ms] Max [ms] Relative
revm_ManyHashes 8.7 ± 0.1 8.6 8.8 1.00
levm_ManyHashes 16.4 ± 0.2 16.1 16.7 1.89 ± 0.03

Benchmark Results: BubbleSort

Command Mean [s] Min [s] Max [s] Relative
revm_BubbleSort 3.266 ± 0.050 3.228 3.388 1.00
levm_BubbleSort 5.650 ± 0.033 5.593 5.684 1.73 ± 0.03

Benchmark Results: ERC20 - Transfer

Command Mean [ms] Min [ms] Max [ms] Relative
revm_ERC20Transfer 248.5 ± 1.5 246.7 251.9 1.00
levm_ERC20Transfer 484.7 ± 3.3 479.5 489.5 1.95 ± 0.02

Benchmark Results: ERC20 - Mint

Command Mean [ms] Min [ms] Max [ms] Relative
revm_ERC20Mint 141.0 ± 0.6 139.7 142.0 1.00
levm_ERC20Mint 316.0 ± 4.5 312.0 325.5 2.24 ± 0.03

Benchmark Results: ERC20 - Approval

Command Mean [s] Min [s] Max [s] Relative
revm_ERC20Approval 1.037 ± 0.005 1.030 1.047 1.00
levm_ERC20Approval 1.862 ± 0.021 1.826 1.888 1.80 ± 0.02

Main Results

Benchmark Results: Factorial

Command Mean [ms] Min [ms] Max [ms] Relative
revm_Factorial 239.5 ± 0.8 238.5 241.3 1.00
levm_Factorial 815.6 ± 38.0 795.0 918.5 3.40 ± 0.16

Benchmark Results: Factorial - Recursive

Command Mean [s] Min [s] Max [s] Relative
revm_FactorialRecursive 1.407 ± 0.085 1.308 1.565 1.00
levm_FactorialRecursive 13.866 ± 0.018 13.845 13.908 9.85 ± 0.59

Benchmark Results: Fibonacci

Command Mean [ms] Min [ms] Max [ms] Relative
revm_Fibonacci 214.9 ± 1.0 214.0 217.0 1.00
levm_Fibonacci 793.4 ± 5.5 785.4 801.5 3.69 ± 0.03

Benchmark Results: ManyHashes

Command Mean [ms] Min [ms] Max [ms] Relative
revm_ManyHashes 8.6 ± 0.1 8.5 8.7 1.00
levm_ManyHashes 16.4 ± 0.3 16.1 17.1 1.91 ± 0.03

Benchmark Results: BubbleSort

Command Mean [s] Min [s] Max [s] Relative
revm_BubbleSort 3.236 ± 0.014 3.225 3.272 1.00
levm_BubbleSort 5.649 ± 0.041 5.583 5.730 1.75 ± 0.01

Benchmark Results: ERC20 - Transfer

Command Mean [ms] Min [ms] Max [ms] Relative
revm_ERC20Transfer 247.9 ± 0.9 246.7 249.7 1.00
levm_ERC20Transfer 486.6 ± 4.3 480.5 492.2 1.96 ± 0.02

Benchmark Results: ERC20 - Mint

Command Mean [ms] Min [ms] Max [ms] Relative
revm_ERC20Mint 140.8 ± 3.8 139.0 151.4 1.00
levm_ERC20Mint 315.1 ± 2.5 312.4 321.0 2.24 ± 0.06

Benchmark Results: ERC20 - Approval

Command Mean [s] Min [s] Max [s] Relative
revm_ERC20Approval 1.033 ± 0.004 1.028 1.040 1.00
levm_ERC20Approval 1.853 ± 0.020 1.829 1.881 1.79 ± 0.02

@JulianVentura JulianVentura self-assigned this Apr 16, 2025
@JulianVentura JulianVentura marked this pull request as ready for review April 16, 2025 16:06
@JulianVentura JulianVentura requested a review from a team as a code owner April 16, 2025 16:06
@JulianVentura JulianVentura added this pull request to the merge queue Apr 16, 2025
Merged via the queue into main with commit ac268f1 Apr 16, 2025
@JulianVentura JulianVentura deleted the fix/levm-logs-on-reverts branch April 16, 2025 17:41
@JulianVentura JulianVentura added the testing Hive tests, execution-spec-tests, etc label Apr 21, 2025
pedrobergamini pushed a commit to pedrobergamini/ethrex that referenced this pull request Aug 24, 2025
**Description**

This PR removes logs from the `ExecutionReport` when a transaction
reverts.
With this fix, LEVM no longer breaks at block 80k while syncing on
Holesky testnet.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

testing Hive tests, execution-spec-tests, etc

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants