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

Str-727 Upgrade EL guest code to prove range of N blocks #533

Merged
merged 12 commits into from
Dec 20, 2024

Conversation

MdTeach
Copy link
Contributor

@MdTeach MdTeach commented Dec 10, 2024

Description

Upgrades the current EL guest code and prover manager to support proving the range of EL blocks. The current implementation is designed to prove the STF of a single EL block. This upgrade will generalize the process to handle N blocks.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature/Enhancement (non-breaking change which adds functionality or enhances an existing one)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Refactor
  • New or updated tests
  • Dependency Update

Notes to Reviewers

Checklist

  • I have performed a self-review of my code.
  • I have commented my code where necessary.
  • I have updated the documentation if needed.
  • My changes do not introduce new warnings.
  • I have added tests that prove my changes are effective or that my feature works.
  • New and existing tests pass with my changes.

Related Issues

@MdTeach MdTeach changed the title Str 652 el prove range Str-652 Upgrade EL guest code to prove range of N blocks Dec 10, 2024
@MdTeach MdTeach force-pushed the STR-652-el-prove-range branch from a687b02 to 7d2602b Compare December 10, 2024 18:47
@MdTeach MdTeach marked this pull request as ready for review December 10, 2024 18:48
@MdTeach MdTeach requested review from a team as code owners December 10, 2024 18:48
@MdTeach MdTeach force-pushed the STR-652-el-prove-range branch from 7d2602b to f6b6b2c Compare December 11, 2024 05:46
@MdTeach MdTeach requested a review from a team as a code owner December 11, 2024 10:40
Copy link

codecov bot commented Dec 11, 2024

Codecov Report

Attention: Patch coverage is 65.95745% with 48 lines in your changes missing coverage. Please review.

Project coverage is 56.66%. Comparing base (5008f3d) to head (c7303fb).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
bin/prover-client/src/proving_ops/el_ops.rs 0.00% 18 Missing ⚠️
crates/proof-impl/evm-ee-stf/src/utils.rs 69.04% 13 Missing ⚠️
bin/prover-client/src/prover.rs 0.00% 7 Missing ⚠️
crates/reth/exex/src/prover_exex.rs 0.00% 4 Missing ⚠️
bin/prover-client/src/proving_ops/cl_ops.rs 0.00% 2 Missing ⚠️
bin/prover-client/src/rpc_server.rs 0.00% 2 Missing ⚠️
crates/proof-impl/cl-stf/src/lib.rs 93.75% 1 Missing ⚠️
crates/proof-impl/evm-ee-stf/src/lib.rs 95.45% 1 Missing ⚠️
@@            Coverage Diff             @@
##             main     #533      +/-   ##
==========================================
- Coverage   56.76%   56.66%   -0.11%     
==========================================
  Files         306      308       +2     
  Lines       31263    31316      +53     
==========================================
- Hits        17747    17745       -2     
- Misses      13516    13571      +55     
Files with missing lines Coverage Δ
crates/proof-impl/evm-ee-stf/src/db.rs 48.18% <100.00%> (ø)
crates/proof-impl/evm-ee-stf/src/primitives.rs 100.00% <100.00%> (ø)
crates/proof-impl/evm-ee-stf/src/processor.rs 61.18% <100.00%> (ø)
crates/proof-impl/evm-ee-stf/src/prover.rs 100.00% <100.00%> (ø)
crates/reth/db/src/rocksdb/db.rs 92.07% <100.00%> (+0.41%) ⬆️
crates/reth/rpc/src/lib.rs 0.00% <ø> (ø)
crates/rpc/prover-client-api/src/lib.rs 0.00% <ø> (ø)
crates/test-utils/src/evm_ee.rs 100.00% <100.00%> (ø)
crates/zkvm/adapters/sp1/src/host.rs 0.00% <ø> (ø)
crates/proof-impl/cl-stf/src/lib.rs 93.67% <93.75%> (-2.21%) ⬇️
... and 7 more

... and 8 files with indirect coverage changes

@MdTeach MdTeach force-pushed the STR-652-el-prove-range branch 2 times, most recently from b68ae92 to 2e0f72e Compare December 11, 2024 11:19
@MdTeach MdTeach added the prover Prover-related, extremely sensntive in production label Dec 11, 2024
@john-light john-light changed the title Str-652 Upgrade EL guest code to prove range of N blocks Str-727 Upgrade EL guest code to prove range of N blocks Dec 11, 2024
Copy link
Contributor

@delbonis delbonis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good.

crates/proof-impl/cl-stf/src/lib.rs Outdated Show resolved Hide resolved
Copy link
Contributor

@prajwolrg prajwolrg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good overall!
While we are here let's change the names from EL -> EvmEe

@MdTeach MdTeach force-pushed the STR-652-el-prove-range branch 2 times, most recently from aa0cd3b to 8f11872 Compare December 13, 2024 12:25
@MdTeach MdTeach force-pushed the STR-652-el-prove-range branch from 8f11872 to 0c25603 Compare December 13, 2024 12:26
Copy link
Contributor

@evgenyzdanovich evgenyzdanovich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

bin/prover-client/src/proving_ops/cl_ops.rs Show resolved Hide resolved
@MdTeach MdTeach force-pushed the STR-652-el-prove-range branch from 0c25603 to e09cf99 Compare December 14, 2024 08:52
@MdTeach MdTeach force-pushed the STR-652-el-prove-range branch from 55ca6c5 to 880dacc Compare December 19, 2024 06:37
@MdTeach MdTeach force-pushed the STR-652-el-prove-range branch 4 times, most recently from d2fc9e2 to b4a3301 Compare December 19, 2024 18:19
@MdTeach
Copy link
Contributor Author

MdTeach commented Dec 19, 2024

Is it feasible to define the proof job in terms of the block IDs to avoid the possibility for the block indexes to ever get confused?

Yes, It can be done after #522 where proof_key will be used to reference proof job which will be based on block ID.
Created STR-755 to track this

@MdTeach MdTeach force-pushed the STR-652-el-prove-range branch from b4a3301 to c7303fb Compare December 19, 2024 18:34
Copy link
Member

@storopoli storopoli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK c7303fb

Nice work!

@storopoli storopoli enabled auto-merge December 20, 2024 08:44
@storopoli storopoli added this pull request to the merge queue Dec 20, 2024
Merged via the queue into main with commit 5a42f42 Dec 20, 2024
18 checks passed
@storopoli storopoli deleted the STR-652-el-prove-range branch December 20, 2024 09:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
prover Prover-related, extremely sensntive in production
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants