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

chore: merge upstream changes into develop #28

Merged
merged 107 commits into from
Jun 5, 2024
Merged

Conversation

pythonberg1997
Copy link
Contributor

Description

This pr is to merge upstream changes into develop branch

Rationale

tell us why we need these changes...

Example

add an example CLI or API response...

Changes

Notable changes:

  • add each change in a bullet point here
  • ...

Potential Impacts

  • add potential impacts for other components here
  • ...

rakita and others added 30 commits April 2, 2024 22:08
Bumps [secp256k1](https://github.com/rust-bitcoin/rust-secp256k1) from 0.28.2 to 0.29.0.
- [Changelog](https://github.com/rust-bitcoin/rust-secp256k1/blob/master/CHANGELOG.md)
- [Commits](rust-bitcoin/rust-secp256k1@secp256k1-0.28.2...secp256k1-0.29.0)

---
updated-dependencies:
- dependency-name: secp256k1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
… (#1243)

* feat(interpreter): remove SPEC generic from gas calculation functions

* feat(interpreter): make most gas cost calculation functions `const`

* set_final_refund

* unused

* fix: optimism

* chore: use `is_london: bool` instead of `SpecId` in `Gas::set_final_refund`
* feat: alloydb

* chore: turn on needed deps for test

* derive

* correct address

* chore: remove arc

* feat: actually make Transport and Network generic to accept any transport or network

* chore: condense markers into one, more idiomatic
* fix typo

* fix typo
* check without microbench
* cleanup
* feat: add modifies_memory macro

* refactor
* fix examples->generate_block_traces reuse TracerEip3155.gas_inspector issue

* fmt code

* clear the eip3155 tracer state so that it can be used in next transaction

* print summary and clean state when create_end

* update documentation

* fix left nits

* add cancun upgrade block number

* remove outdated doc

* remove outdated doc

* remove empty file

* TS is unit used to trigger the hardork

---------

Co-authored-by: rakita <rakita@users.noreply.github.com>
* eof

* feat(EOF): Header decoder

* EofBody decode

* disable eof deprecated opcodes

* add eof instructions

* temp tests

* rjump instructions

* eof rjump with tests

* EOF bytecode

* callf, retf, jumpf

* tests for callf,retf,jumpf

* small rename

* add dataload, dataloadn and datacopy opcodes

* refactor calls

* blueprint for creates

* eof create inputs

* some wip

* add eofcreate structs and exccall flow

* wip eofcreate code flow and handlers

* fix tests

* eof creates

* refactor eofcreate a little

* some work on extcall

* feat: refactor simplify CallInput, eof extcalls

* feat: restructure OpCode and add stack input/output num

* add flags for stack_io and not_eof

* wip eof verification

* wip validation

* EOF Bytecode validity

* insturction and jump validation seems good

* merged eof validate function

* EOP test runner, fex fixes

* RETURNDATALOAD, fix call bugs, refactor gas warm/cold calc

* debug session, rjumpv imm fix

* fixing validation bugs, bytecode decoder for EOF in revme

* pass most of validation tests

* bounds check moved to decode

* Fix merge compilation, fmt

* TXCREATE work

* remove training wheels, panic on eof

* test fix and std

* std

* fix test

* fix valgrind

* fix tests

* clippy

* removed checked logic

* small change

* no std revm-test

* check pending TODOs

* build check no_std

* doc

* chore: move some files. cleanup comments

* fix fmt,clippy and compile error
* feat: add flag to force hashbrown usage

* misc: propagate hashbrown feature flag
* feat(revm): make `FrameOrResult` serializable

This commit make all structs under `FrameOrResult` serializable, which
is useful when trying to save execution state inside an inspector during
transaction execution.

The modified structs include:

* revm: `FrameOrResult`, `FrameResult`, `Frame`, `FrameData`,
  `CallFrame`, `CreateFrame`, `JournalCheckpoint`
* interpreter: `BytecodeLocked`, `Contract`, `Gas`, `CreateOutcome`,
  `CallOutcome`, `Interpreter`

* style(interpreter): make clippy happy

* fix(interpreter): fix missing conflict

* style(interpreter): make clippy happy
* fix: correct some stack IO

* chore: remove dead code
Bumps [anyhow](https://github.com/dtolnay/anyhow) from 1.0.81 to 1.0.82.
- [Release notes](https://github.com/dtolnay/anyhow/releases)
- [Commits](dtolnay/anyhow@1.0.81...1.0.82)

---
updated-dependencies:
- dependency-name: anyhow
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
mattsse and others added 26 commits May 15, 2024 11:23
* Revert "feat: implement EIP-2935 (#1354)"

This reverts commit 3e089f3.

* dont revert some commend changes

* Revert "fix(eip2935): Preload blockchash storage address (#1395)"

This reverts commit aeefcda.
* fix: load blockchash only from serve_window

* fix: devnet-0 blockchash behaviour
* test(precompile): add BLS test vectors

* fix(gakonst): dont blow up on bls p2_affines

* uncomment g1 msm required gas

* chore: small refactors

* rm artifacts

* add new bls test jsons

* remove fail-tests

these should be added again at some point

* fix: perform subgroup checks only on msm, pairing, and scalar multiplications

* fix docs

---------

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
Co-authored-by: rakita <dragan0rakita@gmail.com>
Co-authored-by: Dan Cline <6798349+Rjected@users.noreply.github.com>
* chore(interpreter): optimisation for BYTE, SHL, SHR and SAR

* added previus comment in byte function

* updated pr comments
* feat: load account should return db error

* simplify
* chore: cargo update

* chore: skip tests with storage check and return error

* return println and clippy

* revert to previous println
* feat(revm): revert EIP-2935 BLOCKHASH opcode changes

* fix lint

* bump time

* return previous impl mod prague branch

* remove unused imports
* feat(optimism): Add secp256r1 precompile for Fjord

* Fix docs

* Fix nostd build

* Load fjord precompiles via optimism handler register

* Remove outdated fjord() precompile spec constructor

* Document the secp256r1 feature

* Address feedback

* Handle invalid signatures

* Update crates/precompile/src/secp256r1.rs

* Update crates/precompile/src/secp256r1.rs

* Blank return on failed signature verification

* Add test case for invalid (zero) pubkey

---------

Co-authored-by: rakita <rakita@users.noreply.github.com>
* fix: check canonical field elements

* chore: more cleanups

* remove hex, update comments

* fix more docs

* small refactor and check if fp is canonical

* doc fix
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.202 to 1.0.203.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](serde-rs/serde@v1.0.202...v1.0.203)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…me (#1461)

conflict

Co-authored-by: Eric Bogard <ebo@testmachine.ai>
* Implement new L1 cost function for Fjord

* Add fastlz test

* Adds a second, more faithful adaptation of solady fastlz for fuzzing

* Fix bounds check

* Remove some unnecessary constants

* Fix some linting issues

* Add tests for parity with evm bytecode implementation of fastlz

* Replace ethers abi encode/decode with alloy

* Use rstest for parameterized testcases

* Revert change to examples

* Remove duplicate solady flz implementation

* Remove direct alloy-sol-macro dependency

* Remove unnecessary flag check

* Undo dependency reordering
* fix(Interpreter): wrong block number used

* chore(primitives): rename State to PlainState

* Restructure StorageSlot and rename PlainState to EvmState

* doc
# Conflicts:
#	.github/workflows/book.yml
#	.github/workflows/cachegrind.yml
#	Cargo.lock
#	crates/interpreter/src/instructions/opcode.rs
#	crates/precompile/Cargo.toml
#	crates/precompile/src/lib.rs
#	crates/primitives/src/specification.rs
#	crates/revm/src/optimism/handler_register.rs
Copy link
Contributor

github-actions bot commented Jun 4, 2024

Valgrind Results:

==5431== Cachegrind, a cache and branch-prediction profiler
==5431== Copyright (C) 2002-2017, and GNU GPL'd, by Nicholas Nethercote et al.
==5431== Using Valgrind-3.18.1 and LibVEX; rerun with -h for copyright info
==5431== Command: target/release/snailtracer
==5431== 
--5431-- warning: L3 cache found, using its data for the LL simulation.
Running snailtracer example!
elapsed: 1.820279887s
==5431== 
==5431== I   refs:      429,371,393
==5431== I1  misses:          3,192
==5431== LLi misses:          2,826
==5431== I1  miss rate:        0.00%
==5431== LLi miss rate:        0.00%
==5431== 
==5431== D   refs:      206,204,753  (133,650,515 rd   + 72,554,238 wr)
==5431== D1  misses:        344,709  (    204,681 rd   +    140,028 wr)
==5431== LLd misses:        137,607  (      4,259 rd   +    133,348 wr)
==5431== D1  miss rate:         0.2% (        0.2%     +        0.2%  )
==5431== LLd miss rate:         0.1% (        0.0%     +        0.2%  )
==5431== 
==5431== LL refs:           347,901  (    207,873 rd   +    140,028 wr)
==5431== LL misses:         140,433  (      7,085 rd   +    133,348 wr)
==5431== LL miss rate:          0.0% (        0.0%     +        0.2%  )

@unclezoro unclezoro merged commit cd1ce9b into develop Jun 5, 2024
20 checks passed
@pythonberg1997 pythonberg1997 deleted the roshan/merge-upstream branch June 6, 2024 18:43
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.