Skip to content

Commit

Permalink
refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
Okm165 committed Apr 9, 2024
1 parent d12a107 commit a29f71c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
7 changes: 0 additions & 7 deletions src/stark.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -104,12 +104,6 @@ impl StarkProofImpl of StarkProofTrait {
);
// --- END STEP 1 ---

// --- REQUIRED CONTEXT BETWEEN STEP1 & STEP2
// --- queries_hash: felt252
// --- stark_commitment_hash: felt252
// --- stark_domains_hash: felt252

// --- BEGIN STEP 2 --- (queries, stark_commitment, stark_domains, StarkWitness) -> (bool)
// STARK verify phase.
stark_verify::stark_verify(
NUM_COLUMNS_FIRST,
Expand All @@ -119,7 +113,6 @@ impl StarkProofImpl of StarkProofTrait {
*self.witness,
stark_domains
)
// --- END STEP 2 ---
}
}

Expand Down
11 changes: 9 additions & 2 deletions src/stark/stark_verify.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,13 @@ fn stark_verify(
witness: StarkWitness,
stark_domains: StarkDomains,
) {
// --- REQUIRED CONTEXT FOR SUBSTEP 1
// --- queries_hash: felt252
// --- commitment_hash: felt252
// --- stark_domains_hash: felt252

// --- BEGIN SUBSTEP 1 --- (queries, commitment, stark_domains, Witness) -> (fri_decommitment)

// First layer decommit.
traces_decommit(
queries, commitment.traces, witness.traces_decommitment, witness.traces_witness
Expand Down Expand Up @@ -70,12 +77,12 @@ fn stark_verify(
values: oods_poly_evals.span(), points: points.span(),
};

// --- REQUIRED CONTEXT FOR SUBSTEP 1
// --- REQUIRED CONTEXT FOR SUBSTEP 2
// --- queries_hash: felt252
// --- fri_commitment_hash: felt252
// --- fri_decommitment_hash: felt252

// --- BEGIN SUBSTEP 1 --- (queries, fri_commitment, fri_decommitment, fri_witness) -> (bool)
// --- BEGIN SUBSTEP 2 --- (queries, fri_commitment, fri_decommitment, fri_witness) -> (bool)
fri_verify(
queries: queries,
commitment: commitment.fri,
Expand Down

0 comments on commit a29f71c

Please sign in to comment.