zero-knowledge-gadgets icon indicating copy to clipboard operation
zero-knowledge-gadgets copied to clipboard

[TASK] Optimize tests for PLONK gadgets

Open lazovicff opened this issue 4 years ago • 0 comments

Instead of creating a circuit for each test case for our PLONK gadgets, we should use the following function: https://github.com/ZK-Garage/plonk/blob/master/plonk-core/src/constraint_system/composer.rs#L541

The benefits:

  • We could debug in more detail which gate is not satisfying the constraints
  • More performant tests -- we dont need to go trough prove/verify process
  • Smaller code footprint

NOTE: This should only be done for out gadgets: PoseidonGadget, PathGadget, SetGadget

lazovicff avatar Jan 21 '22 09:01 lazovicff