mirror of
https://github.com/logos-storage/plonky2.git
synced 2026-01-07 16:23:12 +00:00
Fix
This commit is contained in:
parent
d091910d79
commit
f4fdb6a12f
@ -24,6 +24,7 @@ pub(crate) fn generate_bootstrap_kernel<F: Field>(state: &mut GenerationState<F>
|
|||||||
// Iterate through chunks of the code, such that we can write one chunk to memory per row.
|
// Iterate through chunks of the code, such that we can write one chunk to memory per row.
|
||||||
for chunk in &KERNEL.code.iter().enumerate().chunks(NUM_GP_CHANNELS) {
|
for chunk in &KERNEL.code.iter().enumerate().chunks(NUM_GP_CHANNELS) {
|
||||||
let mut cpu_row = CpuColumnsView::default();
|
let mut cpu_row = CpuColumnsView::default();
|
||||||
|
cpu_row.clock = F::from_canonical_usize(state.traces.clock());
|
||||||
cpu_row.is_bootstrap_kernel = F::ONE;
|
cpu_row.is_bootstrap_kernel = F::ONE;
|
||||||
|
|
||||||
// Write this chunk to memory, while simultaneously packing its bytes into a u32 word.
|
// Write this chunk to memory, while simultaneously packing its bytes into a u32 word.
|
||||||
@ -38,6 +39,7 @@ pub(crate) fn generate_bootstrap_kernel<F: Field>(state: &mut GenerationState<F>
|
|||||||
}
|
}
|
||||||
|
|
||||||
let mut final_cpu_row = CpuColumnsView::default();
|
let mut final_cpu_row = CpuColumnsView::default();
|
||||||
|
final_cpu_row.clock = F::from_canonical_usize(state.traces.clock());
|
||||||
final_cpu_row.is_bootstrap_kernel = F::ONE;
|
final_cpu_row.is_bootstrap_kernel = F::ONE;
|
||||||
final_cpu_row.is_keccak_sponge = F::ONE;
|
final_cpu_row.is_keccak_sponge = F::ONE;
|
||||||
// The Keccak sponge CTL uses memory value columns for its inputs and outputs.
|
// The Keccak sponge CTL uses memory value columns for its inputs and outputs.
|
||||||
|
|||||||
@ -116,6 +116,7 @@ pub struct CpuStark<F, const D: usize> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl<F: RichField, const D: usize> CpuStark<F, D> {
|
impl<F: RichField, const D: usize> CpuStark<F, D> {
|
||||||
|
// TODO: Remove?
|
||||||
pub fn generate(&self, local_values: &mut [F; NUM_CPU_COLUMNS]) {
|
pub fn generate(&self, local_values: &mut [F; NUM_CPU_COLUMNS]) {
|
||||||
let local_values: &mut CpuColumnsView<_> = local_values.borrow_mut();
|
let local_values: &mut CpuColumnsView<_> = local_values.borrow_mut();
|
||||||
decode::generate(local_values);
|
decode::generate(local_values);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user