-
Notifications
You must be signed in to change notification settings - Fork 94
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
Propagate witness of each Keccak step #1732
Conversation
|
||
let keccak_reset_pre_folding_witness = | ||
|keccak_columns: &mut KeccakColumns<Vec<Fp256<FrParameters>>>| { | ||
// Resize without deallocating |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is not resizing I think.
inverse_round: Vec::with_capacity(domain_size), | ||
flags_bytes: std::array::from_fn(|_| Vec::with_capacity(domain_size)), | ||
pad_suffix: std::array::from_fn(|_| Vec::with_capacity(domain_size)), | ||
round_constants: std::array::from_fn(|_| Vec::with_capacity(domain_size)), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the round constants are always the same no?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, they are fixed. It is a pity we use witness columns to store them. In Kimchi they were passed on as gate coefficients, but with folding we cannot really do that without making instances differ from each other.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Modulo comments
Closes #1695 and #1696.
This PR finalizes the (pre-folding) Keccak integration with the zkVM and Syscalls.
Related issues that would clean-up this code:
KeccakColumns
to reduce clones beforeinto_iter()
insideproof.rs
#1718Pending tasks: