Spectre
Spectre copied to clipboard
SSZ Multiproof
trafficstars
TODO: [x] Clean up some duplicate code [x] Consider removing some of the preprocessor tests which only test individual circuits [x] Fix spec tests
This PR reduces the amount of advice cells being used. We merklize a whole beacon header in circuit when what we really want is just a merkle proof for a couple specific fields. Before:
read params from ./params/kzg_bn254_21.srs
Gate Chip | Phase 0: 11535114 advice cells
Total 2059 fixed cells
Total range check advice cells to lookup per phase: [1222736, 0, 0]
Gate Chip | Phase 0: 1599532 advice cells
Total 1795 fixed cells
Total range check advice cells to lookup per phase: [4096, 0, 0]
test tests::test_both_circuit_sepolia has been running for over 60 seconds
test tests::test_both_circuit_sepolia ... ok
After:
read params from ./params/kzg_bn254_21.srs
Gate Chip | Phase 0: 11182651 advice cells
Total 2035 fixed cells
Total range check advice cells to lookup per phase: [1188896, 0, 0]
Gate Chip | Phase 0: 1598616 advice cells
Total 1767 fixed cells
Total range check advice cells to lookup per phase: [4096, 0, 0]
I've removed the patch to halo2curves in the PR as well :D