diff --git a/Cargo.lock b/Cargo.lock index efc16bdbec..fec5a13de6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2339,7 +2339,7 @@ dependencies = [ [[package]] name = "revm" -version = "8.0.0" +version = "8.0.1" dependencies = [ "anyhow", "auto_impl", @@ -2359,7 +2359,7 @@ dependencies = [ [[package]] name = "revm-interpreter" -version = "4.0.0" +version = "4.0.1" dependencies = [ "revm-primitives", "serde", @@ -2367,7 +2367,7 @@ dependencies = [ [[package]] name = "revm-precompile" -version = "6.0.0" +version = "6.0.1" dependencies = [ "aurora-engine-modexp", "c-kzg", @@ -2384,7 +2384,7 @@ dependencies = [ [[package]] name = "revm-primitives" -version = "3.1.1" +version = "4.0.0" dependencies = [ "alloy-primitives", "auto_impl", @@ -2417,7 +2417,7 @@ dependencies = [ [[package]] name = "revme" -version = "0.4.0" +version = "0.4.1" dependencies = [ "alloy-rlp", "hash-db", diff --git a/bins/revm-test/Cargo.toml b/bins/revm-test/Cargo.toml index 6034e26f1c..0a305bf84e 100644 --- a/bins/revm-test/Cargo.toml +++ b/bins/revm-test/Cargo.toml @@ -7,7 +7,7 @@ edition = "2021" [dependencies] bytes = "1.6" hex = "0.4" -revm = { path = "../../crates/revm", version = "8.0.0",default-features=false } +revm = { path = "../../crates/revm", version = "8.0.1",default-features=false } microbench = "0.5" alloy-sol-macro = "0.7.0" alloy-sol-types = "0.7.0" diff --git a/bins/revme/CHANGELOG.md b/bins/revme/CHANGELOG.md index 34abf0043d..0ef515e7d0 100644 --- a/bins/revme/CHANGELOG.md +++ b/bins/revme/CHANGELOG.md @@ -6,6 +6,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [0.4.1](https://github.com/BigBenlau/revm_ben/compare/revme-v0.4.0...revme-v0.4.1) - 2024-05-02 + +### Other +- updated the following local packages: revm + ## [0.4.0](https://github.com/bluealloy/revm/compare/revme-v0.3.1...revme-v0.4.0) - 2024-04-02 ### Added diff --git a/bins/revme/Cargo.toml b/bins/revme/Cargo.toml index 95290714c3..75b2ba314a 100644 --- a/bins/revme/Cargo.toml +++ b/bins/revme/Cargo.toml @@ -6,7 +6,7 @@ keywords = ["ethereum", "evm"] license = "MIT" repository = "https://github.com/bluealloy/revm" description = "Rust Ethereum Virtual Machine Executable" -version = "0.4.0" +version = "0.4.1" [dependencies] hash-db = "0.15" @@ -15,7 +15,7 @@ hashbrown = "0.14" indicatif = "0.17" microbench = "0.5" plain_hasher = "0.2" -revm = { path = "../../crates/revm", version = "8.0.0", default-features = false, features = [ +revm = { path = "../../crates/revm", version = "8.0.1", default-features = false, features = [ "ethersdb", "std", "serde-json", diff --git a/crates/interpreter/CHANGELOG.md b/crates/interpreter/CHANGELOG.md index 97303ef63a..faa046c0a9 100644 --- a/crates/interpreter/CHANGELOG.md +++ b/crates/interpreter/CHANGELOG.md @@ -6,6 +6,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [4.0.1](https://github.com/BigBenlau/revm_ben/compare/revm-interpreter-v4.0.0...revm-interpreter-v4.0.1) - 2024-05-02 + +### Other +- updated the following local packages: revm-primitives + ## [4.0.0](https://github.com/bluealloy/revm/compare/revm-interpreter-v3.4.0...revm-interpreter-v4.0.0) - 2024-04-02 ### Added diff --git a/crates/interpreter/Cargo.toml b/crates/interpreter/Cargo.toml index e2bc35ffe1..074465fbe1 100644 --- a/crates/interpreter/Cargo.toml +++ b/crates/interpreter/Cargo.toml @@ -6,7 +6,7 @@ keywords = ["no_std", "ethereum", "evm", "revm", "interpreter"] license = "MIT" name = "revm-interpreter" repository = "https://github.com/bluealloy/revm" -version = "4.0.0" +version = "4.0.1" readme = "../../README.md" [package.metadata.docs.rs] @@ -14,7 +14,7 @@ all-features = true rustdoc-args = ["--cfg", "docsrs"] [dependencies] -revm-primitives = { path = "../primitives", version = "3.1.1", default-features = false } +revm-primitives = { path = "../primitives", version = "4.0.0", default-features = false } # optional serde = { version = "1.0", default-features = false, features = [ diff --git a/crates/precompile/CHANGELOG.md b/crates/precompile/CHANGELOG.md index 008c66f604..13ca81e5b0 100644 --- a/crates/precompile/CHANGELOG.md +++ b/crates/precompile/CHANGELOG.md @@ -6,6 +6,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [6.0.1](https://github.com/BigBenlau/revm_ben/compare/revm-precompile-v6.0.0...revm-precompile-v6.0.1) - 2024-05-02 + +### Other +- updated the following local packages: revm-primitives + ## [6.0.0](https://github.com/bluealloy/revm/compare/revm-precompile-v5.1.0...revm-precompile-v6.0.0) - 2024-04-02 ### Fixed diff --git a/crates/precompile/Cargo.toml b/crates/precompile/Cargo.toml index 7690195c9a..8315e3198b 100644 --- a/crates/precompile/Cargo.toml +++ b/crates/precompile/Cargo.toml @@ -6,14 +6,14 @@ keywords = ["no_std", "ethereum", "evm", "revm", "precompiles"] license = "MIT" name = "revm-precompile" repository = "https://github.com/bluealloy/revm" -version = "6.0.0" +version = "6.0.1" [package.metadata.docs.rs] all-features = true rustdoc-args = ["--cfg", "docsrs"] [dependencies] -revm-primitives = { path = "../primitives", version = "3.1.1", default-features = false } +revm-primitives = { path = "../primitives", version = "4.0.0", default-features = false } bn = { package = "substrate-bn", version = "0.6", default-features = false } once_cell = { version = "1.19", default-features = false, features = ["alloc"] } ripemd = { version = "0.1", default-features = false } diff --git a/crates/primitives/CHANGELOG.md b/crates/primitives/CHANGELOG.md index 79148d55ba..5faeccacbc 100644 --- a/crates/primitives/CHANGELOG.md +++ b/crates/primitives/CHANGELOG.md @@ -6,6 +6,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [4.0.0](https://github.com/BigBenlau/revm_ben/compare/revm-primitives-v3.1.1...revm-primitives-v4.0.0) - 2024-05-02 + +### Fixed +- fixed bugs in post_execution.rs + +### Other +- update exectutionResult structure add total_op_count and total_time + ## [3.1.1](https://github.com/bluealloy/revm/compare/revm-primitives-v3.1.0...revm-primitives-v3.1.1) - 2024-04-02 ### Fixed diff --git a/crates/primitives/Cargo.toml b/crates/primitives/Cargo.toml index e3ef145d2b..cab626917d 100644 --- a/crates/primitives/Cargo.toml +++ b/crates/primitives/Cargo.toml @@ -6,7 +6,7 @@ keywords = ["no_std", "ethereum", "evm", "revm", "types"] license = "MIT" name = "revm-primitives" repository = "https://github.com/bluealloy/revm" -version = "3.1.1" +version = "4.0.0" readme = "../../README.md" # Don't need to run build script outside of this repo diff --git a/crates/primitives/src/result.rs b/crates/primitives/src/result.rs index 5a563f7ed5..9a43bd56bf 100644 --- a/crates/primitives/src/result.rs +++ b/crates/primitives/src/result.rs @@ -1,6 +1,7 @@ use crate::{Address, Bytes, Log, State, U256}; use core::fmt; use std::{boxed::Box, string::String, vec::Vec}; +use std::collections::HashMap; /// Result of EVM execution. pub type EVMResult = EVMResultGeneric; @@ -18,7 +19,7 @@ pub struct ResultAndState { } /// Result of a transaction execution. -#[derive(Debug, Clone, PartialEq, Eq, Hash)] +#[derive(Debug, Clone, PartialEq, Eq)] #[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))] pub enum ExecutionResult { /// Returned successfully @@ -28,6 +29,8 @@ pub enum ExecutionResult { gas_refunded: u64, logs: Vec, output: Output, + total_op_count: HashMap, + total_time: HashMap }, /// Reverted by `REVERT` opcode that doesn't spend all gas. Revert { gas_used: u64, output: Bytes }, diff --git a/crates/revm/CHANGELOG.md b/crates/revm/CHANGELOG.md index 1b01a63387..706e121665 100644 --- a/crates/revm/CHANGELOG.md +++ b/crates/revm/CHANGELOG.md @@ -6,6 +6,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [8.0.1](https://github.com/BigBenlau/revm_ben/compare/revm-v8.0.0...revm-v8.0.1) - 2024-05-02 + +### Fixed +- fixed bugs in post_execution.rs +- fixed bugs + +### Other +- add log in transact() + ## [8.0.0](https://github.com/bluealloy/revm/compare/revm-v7.2.0...revm-v8.0.0) - 2024-04-02 ### Added diff --git a/crates/revm/Cargo.toml b/crates/revm/Cargo.toml index 856bc89294..ca9bcfb301 100644 --- a/crates/revm/Cargo.toml +++ b/crates/revm/Cargo.toml @@ -6,7 +6,7 @@ keywords = ["no_std", "ethereum", "evm", "revm"] license = "MIT" name = "revm" repository = "https://github.com/bluealloy/revm" -version = "8.0.0" +version = "8.0.1" readme = "../../README.md" [package.metadata.docs.rs] @@ -15,8 +15,8 @@ rustdoc-args = ["--cfg", "docsrs"] [dependencies] # revm -revm-interpreter = { path = "../interpreter", version = "4.0.0", default-features = false } -revm-precompile = { path = "../precompile", version = "6.0.0", default-features = false } +revm-interpreter = { path = "../interpreter", version = "4.0.1", default-features = false } +revm-precompile = { path = "../precompile", version = "6.0.1", default-features = false } # misc auto_impl = { version = "1.2", default-features = false } diff --git a/crates/revm/src/evm.rs b/crates/revm/src/evm.rs index 76bf4b633c..1a8eaf2351 100644 --- a/crates/revm/src/evm.rs +++ b/crates/revm/src/evm.rs @@ -170,6 +170,7 @@ impl Evm<'_, EXT, DB> { /// This function will validate the transaction. #[inline] pub fn transact(&mut self) -> EVMResult { + println!("Start revm transact"); self.handler.validation().env(&self.context.evm.env)?; let initial_gas_spend = self .handler diff --git a/crates/revm/src/handler/mainnet/post_execution.rs b/crates/revm/src/handler/mainnet/post_execution.rs index a0b81a0dc0..57166574b8 100644 --- a/crates/revm/src/handler/mainnet/post_execution.rs +++ b/crates/revm/src/handler/mainnet/post_execution.rs @@ -5,6 +5,7 @@ use crate::{ }, Context, FrameResult, }; +use std::collections::HashMap; /// Mainnet end handle does not change the output. #[inline] @@ -93,6 +94,8 @@ pub fn output( gas_refunded, logs, output, + total_op_count: HashMap::new(), + total_time: HashMap::new() }, SuccessOrHalt::Revert => ExecutionResult::Revert { gas_used: final_gas_used,