github risc0/risc0 v0.15.0

latest releases: v1.0.0-rc.4, v1.0.0-rc.3, v0.21.0...
11 months ago

This release includes continuations, a mechanism for splitting a large program into several smaller segments that can be computed and proven independently. We’re excited about the benefits continuations provide in terms of features (such as adding the ability to pause & resume a guest), in terms of performance (such as capping the memory requirements for long-running guests), and in terms of functionality (such as the elimination of the cycle count limit on guest programs — you can now run a guest for as long as you are willing to wait).

Along with continuations 0.15 is bringing substantial changes to the zkVM API. We have done our best to highlight key breaking changes in the “Breaking Changes” section below, and we’ve put together a Migration Guide to help developers upgrade from 0.14 to 0.15. If you run into problems while upgrading, we invite you to reach out to us on Discord or open an issue!

Breaking Changes

Because this release includes many breaking API changes, we have also published a migration guide for updating 0.14 code to 0.15.

  • 0.15 depends on a different version of Rust than previous versions.
    • Please update rust-toolchain to channel = "nightly-2023-03-06" from channel = "nightly-2022-10-28"
  • Generation of proofs has been split into two phases: execution & proving.
    • This has many ramifications in the API, and we will discuss major ones below. For full details of the current API, please see the zkVM documentation.
  • risc0_zkvm::Prover has been replaced with risc0_zkvm::Executor
  • risc0_zkvm::ProverOpts has been replaced with risc0_zkvm::ExecutorEnv
  • The API for host-guest communication has been changed on the host side
    • Replace Prover::add_input_u8_slice and Prover::add_input_u32_slice with ExecutorEnvBuilder::add_input
    • If you previously relied on ProverOpts::with_send_recv_callback, consider ExecutorEnvBuilder::io_callback. For some cases, you may instead want to consider ExecutorEnvBuilder::stdin and ExecutorEnvBuilder::stdout. There are other options as well, see the ExecutorEnvBuilder documentation.
    • See the 0.15 Migration Guide for detailed instructions and other cases
  • risc0_zkvm::Receipt is replaced with risc0_zkvm::SessionReceipt which contains a Vec<risc0_zkvm::SegmentReceipt>
  • risc0_zkvm::serde replaces the functionality of risc0-zeroio and so the latter has been removed.

What's Changed

  • Update serial_test requirement from 1.0 to 2.0 by @dependabot in #486
  • Removed Snakecase from risczero new proj name by @mothran in #487
  • Align example project code with latest starter template by @tzerrell in #488
  • Added RISC0_CUDA_OPT and set ptxas opt level to -O1 by @mothran in #492
  • ExecState::segmentize creates execution segments against which proofs may be generated by @shkoo in #482
  • README Getting Started steps have been updated to include new cargo risczero tool by @flaub in #490
  • Update to latest ethers & revm by @flaub in #494
  • Update memory map and drop unused code by @flaub in #491
  • Moved tempdir for risc0-build into cache_dir by @mothran in #497
  • Fixes risc0-build deadlocks on large outputs by @mothran in #498
  • Hash function cleanups by @flaub in #493
  • Added RISC0_GUEST_LOGFILE and fixed clippy warns by @mothran in #499
  • Add system initiated splits to support continuations by @flaub in #469
  • Use generated layout to determine location of registers in rv32im circuit by @shkoo in #476
  • Remove zeroio in favor of risc0_zkvm::serde by @shkoo in #502
  • Add test and example of using stdio through ProverOpts. by @shkoo in #506
  • Move to flashbots RPC for EVM test by @mothran in #508
  • Crates.io validation tooling by @mothran in #501
  • Add serde derives to MemoryImage by @spaugh in #511
  • Delete github-action-benchmark repo directory by @mothran in #512
  • Implementation of new API (as described in Breaking Changes), part 1 by @flaub in #503
  • Document Session and Segment by @tzerrell in #509
  • Add additional sanity checking to the ELF parser by @mothran in #515
  • Added templ_subdir flag to cargo risczero new by @mothran in #517
  • Implementation of new API, part 2 by @flaub in #514
  • Revive profiler, add docs, cleanups by @flaub in #518
  • Update the rust-starter template to match new API by @mothran in #519
  • Replace default_hal with default_prover by @flaub in #520
  • Support Poseidon 254 by @jbruestle in #524
  • Add Clone derive to Segment by @spaugh in #523
  • Added index to Segment / SegmentReceipt by @mothran in #525
  • Move gh-repository location in bench-trend workflow by @mothran in #526
  • Migrate Getting Started into Factors README by @tzerrell in #516
  • Keep CUDA context alive by @flaub in #528
  • Fixing nightly crate validator workflows by @mothran in #522
  • Make MemoryImage::new() failable + bound check by @mothran in #533
  • Added pc to MemoryImage by @mothran in #534
  • Rename risc0/benchmarks to ghpages by @mothran in #537
  • Added running WASM within the zkvm example by @mothran in #539
  • Improve executor perf by @flaub in #536
  • Add BigInt syscall and accelerator in rv32im circuit by @nategraf in #466
  • API adjustment: executor segment callback by @flaub in #540
  • Add mdBook stub by @tzerrell in #527
  • Change the RISC-V circuit semantics for recursions by @jbruestle in #541
  • Update db-dump in crate-validator to fix nightly CI by @mothran in #542
  • Fixed evm block off-by-one, added block_numb arg by @mothran in #544
  • serde: add support to serialize and deserialize 32 bit and 64 bit floating point values by @SchmErik in #545
  • Added libm externs to zkvm guest by @mothran in #543
  • Always provide risc0_zkvm::guest module for easier analyzing, even when not on target=zkvm by @shkoo in #546
  • Remove outdated limitation on EVM example by @tzerrell in #548
  • Fix executor by accounting for extra cycles and patch continuations test for CI by @SchmErik in #556
  • Fix spurious build warning about "duplicate package wordle". by @choongng in #550
  • Use crypto-bigint instead of num-bigint by @nategraf in #547
  • Update to Rust 1.69.0 by @mothran in #553
  • Add FileSegmentRef by @tzerrell in #560
  • Store memory image as a btree of pages by @shkoo in #561
  • Adding feature flag documentation to crate READMEs by @3lkn in #521
  • Update Where's Waldo with syscalls and new hashing traits by @nategraf in #448
  • Adjust image_id to be the hash of (merkle_root, pc) by @flaub in #566
  • Fix for FFI function signature mismatch (issue #569) by @flaub in #570
  • Make sys_sha_buffer available as extern and add RustCrypto sha2 patching example by @nategraf in #567
  • Add error string to opcode decode failure in Executor by @nategraf in #571
  • Workaround to fix self-hosted runners by @flaub in #577
  • Improve receipt docs by @tzerrell in #576

Full Changelog: v0.14.0...v0.15.0

Don't miss a new risc0 release

NewReleases is sending notifications on new releases.