Skip to content

Commit

Permalink
Fix poseidon
Browse files Browse the repository at this point in the history
  • Loading branch information
chriseth committed Sep 13, 2024
1 parent 10d6184 commit 12ffb9f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion std/machines/hash/poseidon_gl_memory.asm
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,8 @@ machine PoseidonGLMemory(mem: Memory, split_gl: SplitGL) with
array::zip(state, c, |state, c| (state' - c) * (1-LAST) = 0);

// In the last row, the first OUTPUT_SIZE elements of the state should equal output
array::zip(output, state, |output, state| LASTBLOCK * (output - state) = 0);
let output_state = array::sub_array(state, 0, OUTPUT_SIZE);
array::zip(output, output_state, |output, state| LASTBLOCK * (output - state) = 0);

// The output should stay constant in the block
array::map(output, |c| unchanged_until(c, LAST));
Expand Down

0 comments on commit 12ffb9f

Please sign in to comment.