Upgrade any OP Stack chain to use ZKPs in just 1 hour with SP1
Today, we’re excited to showcase how combining SP1—a general-purpose zkVM—with OP Stack, a battle-tested rollup framework, creates a zkEVM rollup that is fast, affordable and highly customizable.
Historically, zkEVM rollups have been difficult to build, requiring deep cryptography expertise that makes customization and maintainability complicated and time-consuming. Over the past year, zero-knowledge proofs have made tremendous progress, with zkVMs like SP1 leading the charge. SP1 enables any developer to seamlessly integrate ZKPs using standard Rust code, while delivering fast performance required for real-world applications.
Over the past few months, we collaborated closely with the OP Labs team, to combine the OP Stack, a popular, battle-tested rollup framework, and SP1, a blazing fast zkVM, to create OP Succinct: a seamless way to upgrade ANY existing OP Stack chain to use ZKPs in just 1 hour. With OP Succinct you get:
Reach out today if you want a type-1 zkEVM rollup powered by SP1 (as a new rollup or a simple conversation from an existing rollup).
OP Succinct was built in close collaboration with OP Labs. From day 1, the OP Labs team built the OP Stack to be modular and have a path to supporting a variety of validity mechanisms (not just optimistic fault proofs).
As a part of their open-source initiatives, they recently developed Kona: a Rust implementation of the OP Stack rollup state transition function (STF). With Kona and SP1, we were able to write a simple SP1 program (less than 500 lines of code), to generate a zero-knowledge proof (ZKP) of OP Stack’s STF.
By fitting this ZKP into OP Stack’s modular architecture, it’s easy to convert an OP Stack rollup to a fully proven ZK rollup with incredible features:
For both OP Sepolia and Base, we’ve run our OP Succinct stack (including proof generation + verification onchain) to showcase the viability of providing full validity proving with SP1. Check out the smart contracts that were updated with ZKPs here.
Proving costs are between 0.5-1 cents per transaction (and will drop 5-10x by the end of the year)
We calculated the proving costs of our OP Succinct integration on three OP Stack chains. Check out the results below:
Note: The average proving cost per transaction is cheaper on Base because the gas usage per transaction on Base is 60% of OP Mainnet and OP Sepolia's gas usage per transaction. Additionally, there is a fixed proving overhead per block that is amortized over a larger set of transactions on Base (Base does 50 TPS vs OP Mainnet's 8 TPS for this block range). OP Mainnet and OP Sepolia have similar gas usage per transaction, but OP Mainnet's costs are higher per transaction because of the frequent presence of BN precompiles, which are underpriced relative to the ZK proving cost they incur.
You can use our benchmarking CLI tool to compute these numbers on any arbitrary range of blocks for any OP Stack chain (that uses Ethereum for DA). We calculate the proving costs by running the SP1 STF program for a range of blocks (taken from the chain itself), get the RISC-V cycle count for executing the program, and then calculate how much proving time is required on commodity GPU hardware. From this, we compute the amortized proving cost per transaction. You can look at the full breakdown of results here.
To contextualize costs, the 30-day average transaction fee for Base and Optimism is 2 cents and 5.4 cents respectively. By using OP Succinct, users only have to pay an additional half a cent per transaction to get all the benefits of ZK (other onchain costs such as posting calldata/blobs and verifying proofs on Ethereum remain the same between regular OP Stack rollups and OP Succinct rollups). Already, SP1’s fast performance makes the cost of a fully ZK proven OP Stack rollup practical. But, we also estimate that these costs will go down by 5-10x by the end of the year–read more in the section below.
Fast proof generation allows for fast finality
OP Succinct rollups have fast finality, with a proof for a range of blocks being submitted onchain every 1 hour currently (the same as OP mainnet, although configurable to be lower by the rollup operator). Factoring in proof generation latency with a sufficiently large cluster and more frequent submissions onchain, OP Succinct rollups can easily have a finality on the order of minutes. This allows users to withdraw against this finalized state root as soon as the proof is settled onchain, instead of waiting for 7 days as required by traditional OP stack rollups.
OP Succinct Proposer Service Architecture: The proposer service in OP Succinct rollups generates proofs for a range of blocks (instead of single blocks) to amortize computational overhead associated with deriving state from the L1. Proofs for ranges of blocks are generated in parallel, before aggregation and submission onchain as a single ZKP every hour.
5-10x performance gains are coming
Performance metrics present only a point in time view of cost and latency. However, it’s important to realize that SP1’s performance is rapidly improving every month. Since February, the cost of proving Ethereum blocks with SP1 has decreased 10x from averaging 1 cents to 0.1 cents per transaction.
Through a combination of SP1 performance improvements and protocol and software optimizations to the OP Stack and Kona program, we expect a 5-10x performance boost to OP Succinct rollups by end of year. Optimizations to SP1 are discussed in our performance roadmap section and include a next-generation recursion system, optimizing our 2 phase prover and better arithmetization of our STARKs.
We have many ideas for optimizing the OP Stack’s protocol and the Kona program itself to make programs easier to prove in SP1 (i.e. less RISC-V cycles), including:
The modular design of the OP Stack makes converting an OP Stack rollup to an OP Succinct rollup simple. Conversion requires only 2 steps:
You can find more detailed instructions here and if you intend to use this in production (or testing), please reach out to us!
The lack of underlying change to the OP Stack is a game-changer. We were able to reuse almost all components of the stack, like the sequencer, batcher, op-node, op-geth, etc. Because this integration takes advantage of OP Stack’s modularity and has intentionally minimal surface area (and very few lines of code!), it can neatly integrate into existing deployments, including ones with rollup-as-a-service teams.
Prior to OP Succinct, creating a ZK rollup was very difficult, let alone a Type-1 zkEVM rollup (meaning full EVM compatibility). It is common for most zkEVMs today to not support standard precompiles (like ecpairing) and make tradeoffs with custom data structures for state root computation to be more ZK compatible. But even worse for rollup teams, these zkEVMs require specialized cryptography expertise, making them difficult to customize and maintain.
OP Succinct solves all of these problems. It combines OP Stack, the open-source Rust ecosystem, and SP1 to offer a type-1 zkEVM with the best of all worlds: fast-finality, cheap costs and a great developer experience.
The endgame of Ethereum scaling is that every rollup is a ZK rollup. In this world, users will no longer have to wait 7 days to withdraw funds from a rollup, they will have seamless interoperability across ecosystems, and capital efficiency and verifiability will dramatically improve. With OP Succinct rollups, we have all of these benefits, with a sleek developer experience for rollup teams that allows for customization and maintainability.
With OP Succinct rollups, we can have it all.
Thinking about deploying an OP Succinct rollup or converting your existing rollup to one? Please reach out to us here. If you fit any of the following, we would love to chat with you:
Code: Our code is fully open-source with an MIT license: check out OP Succinct here and SP1 here.
Contribute to SP1: If you’re interested in contributing to SP1 itself, check out the list of open issues in the Github repository!
OP Succinct leverages significant high-quality, open-source work in the Ethereum and Optimism ecosystem, most importantly OP Stack and Kona. We would not have been able to build this without the great work of the OP Labs team, who had the foresight to architect their code as modular and open-source from day 1. We’d also like to specifically thank Clabby and Refcell on the OP team, who created Kona and who we collaborated with closely as we built out this integration. They patiently answered all of our questions and upstreamed a few of our PRs. We want to shout-out Mark Tyneway, Dragan from Revm, and all the members of the Reth team who also helped with this collaboration.
Finally, we want to acknowledge Zach Obront, who worked closely with us for the past few months and spearheaded this integration alongside other members of the Succinct team.
The Succinct ZK residency is a 1 month in-person program hosted in Succinct’s San Francisco Office from September 23rd to October 18th. Recent advances in general-purpose ZK like SP1 have finally made it possible to iterate quickly with ZK with fast performance needed for real-world use-cases.
The purpose of the residency is to bring together teams that are either integrating ZK into an existing product or working on net-new ZK applications to an in-person hub to collaborate, exchange ideas, learn, get feedback and mentorship. Working together IRL to ideate and push the space forward.
(Building with SP1 is not required, the residency is a broader gathering of the ZK ecosystem).
If you are interested in the program, apply now. Applications are accepted on a rolling basis (until August 30th) and due to limited space, we recommend that teams apply as early as possible.
On a personal note–my cofounder John and I met at the 0xPARC summer residency. It was one of the most generative times of my life. The people and teams that came out of that residency are working on the bleeding edge of interesting ideas in ZK & applied cryptography. We want to recreate a similar environment for the ZK builders of today.
Growth Stage ZK Integrators
If you have an established product that is integrating ZK, send engineering talent to work side by side with the Succinct team and other ZK practitioners to ship a year’s worth of progress in an intensely focused “1 month hackathon”.
Early Stage Builders
If you’re early in your product journey and ZK is a core component, join us and work together with other ZK natives for real time protocol design feedback. Get a peek at the bleeding edge of ZK being developed in real time.
Exploration Stage Devs
If you’re a solo builder or small group of devs exploring and experimenting with new ZK-powered ideas, join the residency to collaborate and ideate with others. Come and rapidly iterate through different ideas together.
Confirmed Teams:
Track 1: Upgrade the stack. ZKPs are critical to make blockchains actually scalable and private. This track is ideal for teams who have an existing product they want to make better with ZKPs or teams building next-generation versions of current blockchain infra built with ZKPs from the ground up. Ideas we are excited by include:
Track 2: Real-world ZK. ZKPs have applications even beyond blockchain use cases. There are many teams exploring this nascent space. New ideas that excited us include:
World class advisors and mentors: including Georgios (CTO @ Paradigm, built Reth, Foundry, etc.), Uma Roy (co-founder of Succinct), Dev Ojha (co-founder of Osmosis)
Weekly seminars and Q&A with industry leaders every Tuesday:
Happy hours + team presentations with people across the ecosystem every Thursday
When: September 23rd to October 18th (4 weeks)
Where: The Succinct office (in San Francisco, near the Embarcadero) where every resident will have a dedicated workspace + desks
Stipend: There will be optional shared AirBnbs for housing and weekday meals that will be covered by Succinct. Additional discretionary funding for flights + relocation reimbursement (if not covered by your company) can be covered by Succinct on a case by case basis.
Grant Funding Support: Additional discretionary grant funding is available for builders
Deliverables & Goals: A shipped integration or product throughout the course of the residency, along with a technical write up.
Because applications are accepted on a rolling basis and due to limited space we HIGHLY recommend teams to apply earlier than later. Fill out the application here.
Timeline:
Our updated performance benchmarks for SP1’s latest production-ready release (v1.1.1). Experience unparalleled performance with our new GPU prover.
TL;DR: SP1’s new GPU prover achieves state of the art performance, with the cheapest cloud costs vs. alternative zkVMs by up to 10x, across a diverse set of blockchain workloads like light clients and EVM rollups.
SP1’s performance has improved by an order of magnitude since our launch in February, thanks to relentless performance engineering and our new GPU prover. With SP1’s v1.1.1 release, SP1 is the market-leading zkVM on both performance and cost for workloads like light clients and EVM rollups.
Get started with our latest prover today through the beta version of Succinct’s prover network (sign up here). Top teams like Polygon, Celestia, Avail and more have already generated more than 10,000 proofs and proven trillions of cycles on our prover network.
We benchmark SP1 against RISC0 on three real-world workloads (Tendermint, Reth Block 17106222, and Reth Block 19409768) using a variety of cost-efficient AWS and Lambda Labs GPUs with on-demand pricing.
We note that RISC0’s latest benchmarks against SP1 misleadingly compared our CPU performance to their GPU results. We conducted a fair, apples-to-apples comparison on identical hardware, revealing the significant advantages of our highly optimized GPU prover and precompile-centric architecture.
Our benchmarks are performed across a variety of GPU instances, ranging from AWS g6.xlarge, AWS g6.2xlarge, AWS g6.16xlarge, Lambda Labs NVIDIA A6000, and Lambda Labs NVIDIA A100. We report the cheapest cost across all machines for each zkVM. For more methodology and a raw data sheet, refer to the methodology section.
Key Takeaway. If you’re building a rollup, SP1’s proving costs per block are 10x cheaper than any other zkVM. With readily-available GPU instances on the cloud, SP1 already achieves around a tenth of a cent proving cost per transaction for average Ethereum blocks.
Use it today. If your team wants to take advantage of our GPU prover, it is available on our prover network beta today. Follow the instructions here to sign up. It will be officially available for local usage in the upcoming weeks.
The performance gap between SP1 and alternative zkVMs is attributable to several key factors.
SP1’s precompile-centric architecture. SP1 has support for a flexible precompile system that can accelerate any operation, including secp256k1 and ed25519 signature verification, and sha256 and keccak256 hash functions, decreasing RISC-V cycle counts between 5-10x for many programs. Most real-world workloads (especially light clients and rollups) are dominated by repetitive operations like hashing and elliptic curve operations. SP1 has been designed from the ground up to have its precompiles (which are hand-written, optimized circuits for specific operations) offer performance competitive with ZK circuits for these use-cases, while preserving the flexibility and developer experience of a zkVM.
SP1 is 100% open-source, allowing teams like Argument (formerly known as Lurk Labs) and Scroll to implement custom precompiles for their own use-cases that have dramatically decreased cycle count and accelerated proof generation time. Reach out here if you’re interested in doing something similar.
The idea of precompiles inside zkVMs has become an industry standard since we first introduced SP1, with it becoming a part of RISC0, Valida, Nexus, and Jolt's roadmaps. Today, SP1 is the only production-ready zkVM with extensive precompiles for all the cryptographic operations that matter (keccak256, sha256, secp256k1 and ed25519 signature verification, bn254 and bls12-381 arithmetic, and soon to include bn254 and bls12-381 pairing verification).
A two-phase prover for efficient read-write memory. SP1 uses a novel memory argument which uses a single challenge from the verifier to implement consistent memory across multiple proofs. Because of this, our proof system doesn’t pay the overhead of merkelized memory, which can add significant overhead to proving workloads.
Fundamental proof system efficiencies. We use a lower blowup factor (2 versus 4), use next-generation lookup arguments (i.e., the log derivative-based LogUp), and use a variant of FRI in Plonky3 that allows us to commit to tables of different sizes which gives us more efficient trace area utilization.
We benchmark SP1 on v1.1.1 and RISC0 on v1.0.0. We describe the methodology to our benchmarks below.
We do not benchmark against Valida and Jolt as the projects are still early in development and cannot run most of our benchmarking programs and do not have support for recursion.
Lastly, note that due to the very complex, multi-dimensional nature of zkVM performance (including factors like hardware, single-node vs. multi-node performance, memory usage, recursion cost, hash function selection) these benchmarks only present a simplified view of performance. We tried our best to provide as fair of a comparison as possible, although it is difficult for a single benchmark to capture all nuances.
All benchmarks are reproducible using the repository here and here is a full breakdown of our results.
SP1’s performance is improving everyday and we expect it to continue improving significantly over the upcoming months. A quick preview of what to expect:
In the upcoming weeks, we’ll be sharing a more comprehensive overview of our performance roadmap and the future costs you can expect when proving with SP1.
SP1 is chosen by the best teams for production usage of ZKPs. We’re proud to be working with incredible partners, including Polygon, Celestia, Avail, Hyperlane, Taiko, Sovereign, Nebra, LayerN, Noble, Interchain Foundation, Witness, Nubit, Alpen and many others who are using SP1 for a diversity of use-cases such as rollups, interoperability, bridging, coprocessors, proof aggregation, verifiable attestations and more.
If you’re interested in using SP1 for any of your protocol’s ZKP needs, feel free to get started with the docs and also fill out this form to schedule a call with me or Uma.
In its February release, SP1 did not have recursion and onchain verification, limiting it to offchain use-cases. Today, we are excited to announce the implementation of SP1’s performant STARK recursion, enabling blazing fast end-to-end ZK proof generation with onchain verification on any EVM-compatible chain.
With this testnet launch, SP1 is the fastest, feature-complete zkVM for developers. It is the only zkVM that is fully open-source, supports the Rust standard library, has customizable precompiles for state of the art performance, and leverages the latest techniques in STARKs for performant recursion and onchain verification. Furthermore, SP1’s novel precompile-centric architecture for common operations like hashing, elliptic curve operations, and more allows for an order of magnitude performance gain for blockchain use-cases like ZK rollups, ZK bridges, and more.
Get started with the docs today or clone the project template.
Get started today: Developers can get started by following the installation instructions and creating a new project with “cargo prove new” or cloning the template repo here. Follow the docs to write programs that implement ZK light clients, ZK rollups and more. Using SP1’s SDK, developers can deploy an SP1 EVM verifier to any testnet of their choosing and generate Groth16 proofs that can be verified onchain for ~300,000 gas.
SP1 is the only zkVM with all of the features that developers need:
SP1 Mainnet Timeline: For the past few months, we have been getting SP1 audited by several world-class ZK auditing firms (alongside Plonky 3, one of SP1’s core open-source dependencies). Expect more details on SP1’s mainnet timeline in the upcoming weeks!
Over the past few months, SP1’s performance has improved significantly thanks to support for AVX-512 in Plonky3, batched lookup arguments, optimized prover memory usage, and improved arithmetization. We benchmark SP1 and Risc0 on end to end proving time to get an onchain verifiable proof on a suite of realistic programs, including Merkle proof verification, a Tendermint light client and a type 1 zkEVM that leverages Reth.
We’re excited to see the vision of a precompile-centric architecture for zkVMs become a standard across the industry. RISC0 and Jolt have both recently announced that their roadmaps include adding support for precompiles. It will be interesting to revisit these results when these features get implemented by others.
Note that benchmarking is always a point in time comparison and given the complex, multi-dimensional nature of zkVM performance, any benchmark presents only a simplified view of performance. We choose to benchmark on CPU, similar to the open-source JOLT zkVM benchmark repo, but Risc0 also has support for GPUs.
To build performant recursion, we built an entirely new proving stack (the first open-source zkVM recursion stack) that allows for programmable verification of SP1 proofs.
We believe that this toolchain, including our recursion DSL and recursion compiler, are generally useful public goods that can be utilized by many different teams to implement recursion for new proof systems, including JOLT and Binius. Please reach out to us if you’re interested in using this tooling and we are happy to provide guidance!
We also benchmark SP1 against the newly released JOLT to provide an updated view of how SP1 compares, given its latest performance improvements. JOLT is still a work in progress, and currently does not support recursion or on-chain verification, cannot accelerate workloads with precompiles, has a relatively small upper bound on the maximum cycle count (~16 million), and only supports the RISCV32I variant of RISC-V which does not support instructions for multiplications or divisions. As a result, we can only benchmark JOLT on simple programs, such as their SHA-2 chain program used in their benchmarks (shown below). Nonetheless, given JOLT’s recency and room for further optimizations, we are impressed with its performance and find it quite an interesting line of work.
We show that SP1 out-performs JOLT for similar proof size and similar cycle count.
End to end benchmarking on recursion and time to get to EVM verifiable Groth16 proof.
Benchmarking Methodology
The benchmarking programs can be found in this repo, including Merkle Proof Verification (SSZ withdrawals), the Tendermint ZK Light Client and SP1-Reth. For each program, we generated a proof for both zkVMs, and patched all relevant crates (including the revm, reth, sha2, crypto-bigint, curve25519-dalek and k256 crates). The “# of Cycles'” column is the number of RISC-V instructions executed by the program. The proof generation time is in seconds. Note that the cycle count for the Tendermint and Reth program is provided as 2 numbers because it is significantly smaller in the SP1 zkVM because of SP1's first-class support for precompiles. Note that all the times in the above table do not represent latency as that can be decreased with parallelized proof generation across the core and recursive stages. The core proving time + recursive proving time is the time it takes to get to a constant-sized proof. Note that SP1’s Groth16 wrapper time also includes a “shrinking” stage not present in Risc0 that adds a constant overhead of ~50 seconds, which is why the timing in that phase is longer.
SP1 was benchmarked using the poseidon2 hash function and all standard settings. All other settings were the default Risc0 prover settings in their version 0.21 release. The benchmark was run on a AWS Linux CPU machine (r7i.16xlarge) with 64 vCPUs and 512GB of RAM, with a 3-year reserved pricing of $1.92 per hour.
SP1 vs. JOLT benchmark
We benchmark JOLT with its default settings and SP1 using the poseidon hash function and with a shard size of 2^21 to make the proof size comparable to JOLT’s. The benchmark was run on a AWS Linux CPU machine (r7i.16xlarge) with 64 vCPUs and 512GB of RAM, with a 3-year reserved pricing of $1.92 per hour.
NB: Note that due to the very complex, multi-dimensional nature of zkVM performance (including factors like hardware, single-node vs. multi-node performance, memory usage, recursion cost, hash function selection) these benchmarks only present a simplified view of performance. We tried our best to provide as fair of a comparison as possible, although it is difficult for a single benchmark to capture all nuances.