diff --git a/lib/src/protocol_instance.rs b/lib/src/protocol_instance.rs index dd4b82c1a..5e348bb79 100644 --- a/lib/src/protocol_instance.rs +++ b/lib/src/protocol_instance.rs @@ -11,7 +11,7 @@ use crate::{ primitives::{ eip4844::{self, commitment_to_version_hash}, keccak::keccak, - }, + }, CycleTracker, }; use reth_evm_ethereum::taiko::ANCHOR_GAS_LIMIT; @@ -44,15 +44,19 @@ impl ProtocolInstance { commitment_to_version_hash(&commitment.clone().try_into().unwrap()); match get_blob_proof_type(proof_type, input.taiko.blob_proof_type.clone()) { crate::input::BlobProofType::ProofOfEquivalence => { + let ct = CycleTracker::start("proof_of_equivalence"); let points = eip4844::proof_of_equivalence(&input.taiko.tx_data, &versioned_hash)?; + ct.end(); proof_of_equivalence = (U256::from_le_bytes(points.0), U256::from_le_bytes(points.1)); } crate::input::BlobProofType::ProofOfCommitment => { + let ct = CycleTracker::start("proof_of_commitment"); ensure!( commitment == &eip4844::calc_kzg_proof_commitment(&input.taiko.tx_data)? ); + ct.end(); } }; versioned_hash diff --git a/provers/sp1/contracts/Raiko.sol b/provers/sp1/contracts/Raiko.sol deleted file mode 100644 index 8fe6e052b..000000000 --- a/provers/sp1/contracts/Raiko.sol +++ /dev/null @@ -1,39 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.25; - -import {ISP1Verifier} from "@sp1-contracts/ISP1Verifier.sol"; - -/// @title Raiko. -/// @author Taiko Labs -/// @notice This contract implements a simple example of verifying the proof of a computing a -/// raiko number. -contract Raiko { - /// @notice The address of the SP1 verifier contract. - /// @dev This can either be a specific SP1Verifier for a specific version, or the - /// SP1VerifierGateway which can be used to verify proofs for any version of SP1. - /// For the list of supported verifiers on each chain, see: - /// https://github.com/succinctlabs/sp1-contracts/tree/main/contracts/deployments - address public verifier; - - /// @notice The verification key for the raiko program. - bytes32 public raikoProgramVkey; - - - constructor(address _verifier, bytes32 _raikoProgramVkey) { - verifier = _verifier; - raikoProgramVkey = _raikoProgramVkey; - } - - /// @notice The entrypoint for verifying the proof of a Raiko number. - /// @param proof The encoded proof. - /// @param publicValues The encoded public values. - function verifyRaikoProof(bytes calldata proof, bytes calldata publicValues) - public - view - returns (bytes32) - { - ISP1Verifier(verifier).verifyProof(raikoProgramVkey, publicValues, proof); - bytes32 pi_hash = abi.decode(publicValues, (bytes32)); - return pi_hash; - } -} diff --git a/provers/sp1/contracts/remappings.txt b/provers/sp1/contracts/remappings.txt deleted file mode 100644 index af31e44ee..000000000 --- a/provers/sp1/contracts/remappings.txt +++ /dev/null @@ -1 +0,0 @@ -@forge-std/=./lib/sp1-contracts/contracts/lib/forge-std/src \ No newline at end of file diff --git a/provers/sp1/contracts/src/fixtures/fixture.json b/provers/sp1/contracts/src/fixtures/fixture.json index dcbe46710..7248f9c01 100644 --- a/provers/sp1/contracts/src/fixtures/fixture.json +++ b/provers/sp1/contracts/src/fixtures/fixture.json @@ -1,5 +1,5 @@ { - "vkey": "0x00ae5a8bb64ff1af3963fb06761d52680c27dc24e001e6c836f90207a65d7bff", - "publicValues": "0xeb96af1cf485879a9445ff858ad51c9d43e28338d14d3afa1968c70f7e269cc1", + "vkey": "0x008c04e3628cc5df0d309172e1e792b8c4510b0dee649aea91d46cf388a3f66f", + "publicValues": "0x1dcbde58978cb74970a758e6071b296fb0444ef536d3a9180b997a6b94503a40", "proof": "0x" } \ No newline at end of file diff --git a/provers/sp1/guest/elf/sp1-guest b/provers/sp1/guest/elf/sp1-guest index aab2c2a53..53718d909 100755 Binary files a/provers/sp1/guest/elf/sp1-guest and b/provers/sp1/guest/elf/sp1-guest differ