Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(State): Preserve original values on delete revert #1010

Merged
merged 2 commits into from
Jan 25, 2024
Merged

Conversation

rakita
Copy link
Member

@rakita rakita commented Jan 25, 2024

Delete an account from bundle state only if the original value is None, if we delete non original value we will lose this information.

Original account None means that account din't exist.

On revert if we want to revert on non existing account this means that it is not existing, so we revert on non existing account.

Copy link
Contributor

github-actions bot commented Jan 25, 2024

Valgrind Results:

==3998== Cachegrind, a cache and branch-prediction profiler
==3998== Copyright (C) 2002-2017, and GNU GPL'd, by Nicholas Nethercote et al.
==3998== Using Valgrind-3.18.1 and LibVEX; rerun with -h for copyright info
==3998== Command: target/release/snailtracer
==3998== 
--3998-- warning: L3 cache found, using its data for the LL simulation.
Snailtracer Host+Interpreter benchmark (2.1s) ...            not enough samples
==3998== 
==3998== I   refs:      455,347,843
==3998== I1  misses:         10,973
==3998== LLi misses:          2,892
==3998== I1  miss rate:        0.00%
==3998== LLi miss rate:        0.00%
==3998== 
==3998== D   refs:      237,388,372  (160,564,942 rd   + 76,823,430 wr)
==3998== D1  misses:        349,184  (    208,878 rd   +    140,306 wr)
==3998== LLd misses:        137,561  (      4,049 rd   +    133,512 wr)
==3998== D1  miss rate:         0.1% (        0.1%     +        0.2%  )
==3998== LLd miss rate:         0.1% (        0.0%     +        0.2%  )
==3998== 
==3998== LL refs:           360,157  (    219,851 rd   +    140,306 wr)
==3998== LL misses:         140,453  (      6,941 rd   +    133,512 wr)
==3998== LL miss rate:          0.0% (        0.0%     +        0.2%  )

@rakita
Copy link
Member Author

rakita commented Jan 25, 2024

closes paradigmxyz/reth#5852 and paradigmxyz/reth#5917

@rakita rakita merged commit 5431bd2 into main Jan 25, 2024
25 checks passed
@github-actions github-actions bot mentioned this pull request Jan 25, 2024
Rjected pushed a commit to Rjected/revm that referenced this pull request Jan 26, 2024
* fix(State): Preserve original values on delete revert

* clear storage only if original is None

(cherry picked from commit 5431bd2)
rakita added a commit that referenced this pull request Jan 26, 2024
* fix(State): Preserve original values on delete revert

* clear storage only if original is None

(cherry picked from commit 5431bd2)

Co-authored-by: rakita <rakita@users.noreply.github.com>
@rakita rakita deleted the delete_revert branch February 7, 2024 12:46
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.

None yet

1 participant