aztec-packages
aztec-packages copied to clipboard
feat: Poseidon2 gates for Ultra arithmetisation
Add Poseidon2 gates to the UltraCircuitBuilder
which now ensures that recursive verifier instantiated with the Ultra arithmetisation produce the correct number of constraints.
Updates required:
- change verification key length and constant proof length constants across the codebase (two selectors from the new gate whose commitments need to be in the vk and the poseidon relation becomes the one with the highest degree); changes to Prover.toml accordingly
- ensure the ultra recursive verifier still stays constant size now that hashing produces gates
- small modification to solidity verifer to reflect the ones in cpp with the caveat that the UltraKeccak flavor still doesnt support Poseidon gate (changes coming in a followup PR)
Tube circuit changes in # of gates (post finalisation):
- number of gates prior this change, in master: 13947018
- number of gates post this change: 14038982
Closes https://github.com/AztecProtocol/barretenberg/issues/1041