refactor(precompile): make use of padding utilities, simplify secp256k1#1073
Merged
rakita merged 2 commits intobluealloy:mainfrom Feb 11, 2024
Merged
refactor(precompile): make use of padding utilities, simplify secp256k1#1073rakita merged 2 commits intobluealloy:mainfrom
rakita merged 2 commits intobluealloy:mainfrom
Conversation
rakita
reviewed
Feb 11, 2024
|
|
||
| let mut output = [0u8; 32]; | ||
| hasher.finalize_into((&mut output[12..]).into()); | ||
| Ok((gas_used, output.to_vec())) |
Member
There was a problem hiding this comment.
The previous version seems better
Collaborator
Author
There was a problem hiding this comment.
::digest returns a new array so this avoids the copy_from_slice by directly using the output buffer
rakita
reviewed
Feb 11, 2024
crates/precompile/src/lib.rs
Outdated
| #[inline] | ||
| pub fn get(&self, address: &Address) -> Option<Precompile> { | ||
| self.inner.get(address).cloned() | ||
| pub fn get(&self, address: &Address) -> Option<&Precompile> { |
Member
There was a problem hiding this comment.
Precompile is just a function, as we know concrete type, it is okay to clone it
rakita
reviewed
Feb 11, 2024
| } else { | ||
| gas.as_limbs()[0] | ||
| } | ||
| gas.saturating_to() |
CeciliaZ030
added a commit
to CeciliaZ030/revm
that referenced
this pull request
Feb 22, 2024
CeciliaZ030
added a commit
to CeciliaZ030/revm
that referenced
this pull request
Mar 27, 2024
commit b960c3f Merge: 983db4b 70ab8b6 Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Fri Jan 19 03:28:32 2024 +0800 Merge remote-tracking branch 'cecilia/main' into sync-taiko-v3.5 commit 983db4b Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Fri Jan 19 03:21:10 2024 +0800 non exclusive op & taiko flags commit 115d5fe Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Fri Jan 19 03:11:48 2024 +0800 cleanup commit 7b0065b Merge: c306f98 9d655c4 Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Fri Jan 19 03:06:29 2024 +0800 Merge remote-tracking branch 'cecilia/main' into sync-taiko-v3.5 commit c306f98 Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Fri Jan 19 03:02:19 2024 +0800 handler register commit 72a085e Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Thu Jan 18 16:02:07 2024 +0800 fix specs and conditional op/taiko flags, todo: taiko handlers commit 3ec69ee Merge: a983b13 9a03c7e Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Thu Jan 18 16:01:11 2024 +0800 Merge remote-tracking branch 'cecilia/serde-no-std' into sync-taiko-v3.5 commit 9a03c7e Merge: cf4da2f 0629883 Author: CeciliaZ030 <45245961+CeciliaZ030@users.noreply.github.com> Date: Thu Jan 18 14:44:30 2024 +0800 Merge branch 'main' into serde-no-std commit cf4da2f Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Thu Jan 18 14:35:37 2024 +0800 "preserve_order" commit 6f95113 Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Thu Jan 18 14:33:28 2024 +0800 delete comment #"std" commit 15c51fa Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Thu Jan 18 13:30:33 2024 +0800 optional serde std commit a983b13 Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Thu Jan 18 13:30:33 2024 +0800 optional serde std commit 546cb51 Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Thu Jan 18 12:47:50 2024 +0800 update commit f0d6806 Author: Leo Alt <leo@ethereum.org> Date: Fri Nov 24 16:32:08 2023 +0100 use serde as no-std commit 0546172 Merge: c7aee3a 327dc05 Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Wed Jan 17 03:46:52 2024 +0800 Merge remote-tracking branch 'john/feat/taiko' into cecilia-taiko commit c7aee3a Author: ceciliaz030 <zhangyixin319@gmail.com> Date: Wed Jan 17 03:11:35 2024 +0800 init commit 327dc05 Author: john xu <john@taiko.xyz> Date: Mon Dec 18 06:58:08 2023 +0000 Refactor handler functions in EVM implementation commit 2e96144 Author: john xu <john@taiko.xyz> Date: Sat Dec 9 07:59:10 2023 +0000 Add condition to disable gas refund for anchor transactions commit 13c2272 Author: john xu <john@taiko.xyz> Date: Sat Dec 9 07:21:01 2023 +0000 Remove once_cell dependency commit 6c6b061 Author: john xu <john@taiko.xyz> Date: Sat Dec 9 07:13:20 2023 +0000 Add taiko module and handler commit cbbfe9c Author: Leo Alt <leo@ethereum.org> Date: Fri Nov 24 16:32:08 2023 +0100 use serde as no-std commit 0e7d779 Author: john xu <john@taiko.xyz> Date: Thu Oct 19 12:28:10 2023 +0000 feat: anchor check in zeth commit daf73ee Author: john xu <john@taiko.xyz> Date: Tue Oct 17 13:18:20 2023 +0000 feat: support taiko protocol taiko reimburse_caller & reward_beneficiary KATLA is before CANCUN, aka does not have 4844 --features taiko more registers update pub mod handler_register Update Cargo.toml manual pick: bluealloy/pull/1073 & succinct/john/v5.0.0-patched update c-kzg 1.0.0 latest bump compiled
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
... and some other minor refactors.
In secp256k1 both backends expect a 64-byte signature and the recovery ID in two separate arguments, therefor there is no point in packing them into a 65-byte array only to unpack them right after.