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

Fix issues #191

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion circuits/src/memory/memory_stark.rs
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ impl<F: RichField + Extendable<D>, const D: usize> Stark<F, D> for MemoryStark<F
* (nv_region_heap - region_heap - P::ONES)
* (nv_addr - addr - nv_diff_addr),
);
// constaint rw_addr_unchanged, for stack and heap
// constraint rw_addr_unchanged, for stack and heap
yield_constr.constraint_transition(
(P::ONES - nv[COL_MEM_TX_IDX] + lv[COL_MEM_TX_IDX])
* (P::ONES - nv[COL_MEM_ENV_IDX] + lv[COL_MEM_ENV_IDX])
Expand Down
2 changes: 1 addition & 1 deletion client/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ fn main() {
)
.subcommand(
Command::new("verify")
.about("verifiy generated proof")
.about("verify generated proof")
.args(&[arg!(-i --input <Trace> "Must set a proof file generated by OlaVM prover")])
.arg_required_else_help(true),
)
Expand Down
4 changes: 2 additions & 2 deletions plonky2/plonky2/src/gates/low_degree_interpolation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ impl<F: RichField + Extendable<D>, const D: usize> LowDegreeInterpolationGate<F,
self.end_coeffs() + i - 2
}

/// `powers_evalutation_point(i)` is the wire index of
/// `evalutation_point^i`.
/// `powers_evaluation_point(i)` is the wire index of
/// `evaluation_point^i`.
pub fn powers_evaluation_point(&self, i: usize) -> Range<usize> {
debug_assert!(0 < i && i < self.num_points());
if i == 1 {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ unsafe fn add_with_wraparound(a: u64, b: u64) -> u64 {
adj = lateout(reg) adj,
options(pure, nomem, nostack),
);
res + adj // adj is EPSILON if wraparound occured and 0 otherwise
res + adj // adj is EPSILON if wraparound occurred and 0 otherwise
}

/// Subtraction of a and (b >> 32) modulo ORDER accounting for wraparound.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ use crate::hash::poseidon::{

const WIDTH: usize = 12;

// These tranformed round constants are used where the constant layer is fused with the preceeding
// These transformed round constants are used where the constant layer is fused with the preceeding
// MDS layer. The FUSED_ROUND_CONSTANTS for round i are the ALL_ROUND_CONSTANTS for round i + 1.
// The FUSED_ROUND_CONSTANTS for the very last round are 0, as it is not followed by a constant
// layer. On top of that, all FUSED_ROUND_CONSTANTS are shifted by 2 ** 63 to save a few XORs per
Expand Down Expand Up @@ -183,10 +183,10 @@ unsafe fn const_layer(
// occur if all round constants are < 0xffffffff00000001 = ORDER: if the high bits are
// 0xffffffff, then the low bits are 0, so the carry bit cannot occur. So this trick is valid
// as long as all the round constants are in canonical form.
// The mask contains 0xffffffff in the high doubleword if wraparound occured and 0 otherwise.
// The mask contains 0xffffffff in the high doubleword if wraparound occurred and 0 otherwise.
// We will ignore the low doubleword.
let wraparound_mask = map3!(_mm256_cmpgt_epi32, state_s, res_maybe_wrapped_s);
// wraparound_adjustment contains 0xffffffff = EPSILON if wraparound occured and 0 otherwise.
// wraparound_adjustment contains 0xffffffff = EPSILON if wraparound occurred and 0 otherwise.
let wraparound_adjustment = map3!(_mm256_srli_epi64::<32>, wraparound_mask);
// XOR commutes with the addition below. Placing it here helps mask latency.
let res_maybe_wrapped = map3!(_mm256_xor_si256, res_maybe_wrapped_s, rep sign_bit);
Expand Down