mirror of
https://github.com/logos-storage/plonky2.git
synced 2026-01-09 09:13:09 +00:00
Apply Nicholas comment
This commit is contained in:
parent
56ebda4981
commit
8541a04b4c
@ -211,7 +211,11 @@ impl<F: RichField + Extendable<D>, const D: usize> KeccakSpongeStark<F, D> {
|
||||
operations: Vec<KeccakSpongeOp>,
|
||||
min_rows: usize,
|
||||
) -> Vec<[F; NUM_KECCAK_SPONGE_COLUMNS]> {
|
||||
let mut rows = Vec::with_capacity(operations.len().max(min_rows).next_power_of_two());
|
||||
let base_len: usize = operations
|
||||
.iter()
|
||||
.map(|op| op.input.len() / KECCAK_RATE_BYTES + 1)
|
||||
.sum();
|
||||
let mut rows = Vec::with_capacity(base_len.max(min_rows).next_power_of_two());
|
||||
for op in operations {
|
||||
rows.extend(self.generate_rows_for_op(op));
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user