forked from privacy-scaling-explorations/zkevm-circuits
-
Notifications
You must be signed in to change notification settings - Fork 391
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DA Compression Witness Generation and Assignments (#1232)
* Remove deprecate tests * Remove zstd encoding of literals * Remove raw/rle blocks * Remove block raw/rle scenarios * Remove lstream tag * Remove raw/rle bytes processing * Literals witness row assignment * Remove huffman code component from witness * Add witness rows to sequence section * Add debug flags * Add sequence instruction table witness * Finish recovering original input. sequence decoding done * Add witness rows for sequence FSE tables * Add witness rows for sequence header * Remove debug flags * fmt * Add debug flags * Add debug flags * Add debug flags * Add unit tester * Update Fse construction * Correct fse construction * Correct tag length * Temporarily recover const * Assign literals header rows * Assign columns * Resolve merge compile errors * Modify tag config assignment * Correct block config from witgen * Assign additional seq bitstream fields * Correct tags * configure gadgtes * Add more data fields onto fse * Correct fse assignment * fmt * Remove debug flags * fmt * Fix witness assignment error * fmt * Increase fse fixed capacity * Correct bitstream column assignmnet * Correct assignment for bitstring table * fmt * Correct comment * Remove FseSymbol * Rename FSE section * Recover tests * Correct block header assignment * Correct fse decoder assignment * fmt * Remove constants * Add debug flags * Correct offset increment * Assign padding * Isolate gates * Remove gates * Remove gates * Remove gates * Remove gates * Adjust gates * Recover gates * fix: q_enable fixed column to avoid active gates on unusable rows * wip dbg: non-padded rows except first row * fix: tag transition has been fixed * fix(witgen): tag is_change=true * wip(dbg:gate): continue same tag * fix: compilation (u8 table load) and fhd gate works * fix: fcs OK || unusable_rows=14 * test: fcs is OK * fix(gate): tag=BlockHeader OK * test(lookup): tag=BlockHeader Block_Size OK * test(gate): processing block content OK * fix(gate+lookup): literals header and literals header table * fix(gate): tag=RawBytes OK * fix(gate): tag=SequencesHeader (header decoder fixed order of bits) * fix(fse): sorted state table (partially) * wip(fse sorted states): gates active on unusable rows? * fix(fse): fse table and sorted table OK * witgen: bitstring table OK * Correct skipped bitstream rows * Recover gadgets * Recover gadgets * Recover gadgets * Recover gates * Recover gates * Recover component * Recover constraint * Recover constraints * Recover gates * Recover gates * Recover constraints * Recover constraints * Recover constraints * Recover constraints * fix(lookup): var-bit-packing and other rows of tag=FseCode * restore gate * fix(lookup): bitstream table lookup (start + end) * Correct sequence data init * Correct fse in sequence data decoding * Recover gates * Recover constraints * fix(lookup): interleaved order lookup OK * fix(gate): tag=Null OK * Correct states, symbols, values in bitstream decoding witness * Adjust gates * Adjust fixed table * Remove debug flag * fix(fse_decoder): is_mlt and is_mot expr computation * fse table lookup OK * Correct seq_idx * Recover constraints * Recover gate * fix: constraints updated * chore: degree-overflow fix * Remove is_next_null condition * Add next_nb * Correct tail end bit read idx * fix: update various cases of nil * Correct nil row index * Correct bitstream decoding idx * `SequenceInstructionTable` and `SequenceExecutionConfig` (#1259) * rebase to upstream Signed-off-by: noelwei <fan@scroll.io> * wip of addrtable Signed-off-by: noelwei <fan@scroll.io> * all gates Signed-off-by: noelwei <fan@scroll.io> * change the lookup purpose Signed-off-by: noelwei <fan@scroll.io> * fix according to reviews * purge unused seqvaluetable Signed-off-by: noelwei <fan@scroll.io> * change zero testing to corresponding gadget complete assignment Signed-off-by: noelwei <fan@scroll.io> * trivial fixing Signed-off-by: noelwei <fan@scroll.io> * purge the duplicated works Signed-off-by: noelwei <fan@scroll.io> * unit test (WIP) Signed-off-by: noelwei <fan@scroll.io> * seq exec circuit (WIP) Signed-off-by: noelwei <fan@scroll.io> * seq exec circuit (WIP) Signed-off-by: noelwei <fan@scroll.io> * seq exec circuit (WIP) Signed-off-by: noelwei <fan@scroll.io> * output region: gates and lookups (WIP) Signed-off-by: noelwei <fan@scroll.io> * pass unittest for seqinst table Signed-off-by: noelwei <fan@scroll.io> * seq exec: complete the seq num lookup Signed-off-by: noelwei <fan@scroll.io> * add seq exec info in witgen Signed-off-by: noelwei <fan@scroll.io> * assign and unit tests (WIP) Signed-off-by: noelwei <fan@scroll.io> * refactor for better assignment Signed-off-by: noelwei <fan@scroll.io> * assignments and unit tests (WIP) Signed-off-by: noelwei <fan@scroll.io> * induce debug utilities in AddressRow Signed-off-by: noelwei <fan@scroll.io> * pass first unit test (WIP) Signed-off-by: noelwei <fan@scroll.io> * chore: integrate seq-inst-table and seq-exec-config into decoder-config * refactor to low degree Signed-off-by: noelwei <fan@scroll.io> * more unittest for seq exec (WIP) Signed-off-by: noelwei <fan@scroll.io> * pass unit tests Signed-off-by: noelwei <fan@scroll.io> * add assign entry Signed-off-by: noelwei <fan@scroll.io> * update some witgens, pass decoder's unit test Signed-off-by: noelwei <fan@scroll.io> * integrate seq exec into decoder (WIP) Signed-off-by: noelwei <fan@scroll.io> * temporary disable 3 lookups and unit test pass for the rest Signed-off-by: noelwei <fan@scroll.io> * all of the unit test passed Signed-off-by: noelwei <fan@scroll.io> * trivial updates: head condition in seq exec and exported cells Signed-off-by: noelwei <fan@scroll.io> * clear the warnings Signed-off-by: noelwei <fan@scroll.io> * chore: fmt --------- Signed-off-by: noelwei <fan@scroll.io> Co-authored-by: Rohit Narurkar <rohit.narurkar@proton.me> * chore: most clippy issues/warnings resolved * wip(dbg): decode encoded batch data * fix: literals header's size format bits * DA-Compression (Missing Pieces for single encoded batch) (#1263) * Fix repeated match byte slice: * Add batch witgen test * Adjust test * fix: handle predefined table appropriately in table reconstruction * Skip predefined fse tables: * Add copy constraints and assigned exports * wip dbg: expected vs got * fix: rlc_acc and rlc, handle is_reverse approprately * fix decoder rlc (#1266) Signed-off-by: noelwei <fan@scroll.io> Co-authored-by: Rohit Narurkar <rohit.narurkar@proton.me> * fix: constraints/lookups OK for batch0000 * fix: literal header assignment fix, batch127 failure * Add tag transition fix for fse * fix: fse table handling of prob=-1 and state_idx/sym_count_acc * fix: fse -> seq data order * fix: handle first real symbol in prob=-1 table cases --------- Signed-off-by: noelwei <fan@scroll.io> Co-authored-by: Rohit Narurkar <rohit.narurkar@proton.me> Co-authored-by: Ho <noel.wei@gmail.com> * commit from @noel2004: f181535 * Dbg (large block) (#1270) * data and test * wip dbg: offset > currently decoded (overflow subtraction) * chore: bitwise op table generic over op and range of lhs/rhs * wip dbg: more blobs (witgen fail) * fix: repeat offset usage (ll ==0) and dont include skipped states * Account for nil row in fse * Fix fse nil row byte skip * Correct is_update_state for nil row in sequence data * fix (fse state increasing, but may not be in u8) and fmt * chore: remove println --------- Co-authored-by: Ray Gao <qg2153@columbia.edu> * Refactor/Cleanup Witgen code (#1271) * Remove debug flags * Remove aux data * fmt and add comments * Recover test * Remove import * Recover test * Recover test * Assign padding * Remove unused variables * Remove initial assignment * Add comments * fmt * fmt * fmt * fmt * Organize comments: * tag_value unused | refactor max_len * more refactor and clippy * fix: handle multi-block witgen --------- Co-authored-by: Rohit Narurkar <rohit.narurkar@proton.me> * chore: refactor zstd config into init fn * fix(tag=sequences_data): columns can change iff conditions are met * Support multi-block (#1273) * add test * detour zstd dep Signed-off-by: noelwei <fan@scroll.io> * tbt: test for multi-blob * update zstd dep Signed-off-by: noelwei <fan@scroll.io> * chore: remove unused patch * update zstd (scroll repo) Signed-off-by: noelwei <fan@scroll.io> * Correct multi-block back reference target bytes (#1275) Co-authored-by: Rohit Narurkar <rohit.narurkar@proton.me> * minor fix in assignment (block_info and seq_info) * dbg: fix some issues * dbg: fix bitstring table lookup for byte_idx delta * fix: repeated offsets are carried forward into next block * wip test: large-multi-block * update zstd, set windowlog Signed-off-by: noelwei <fan@scroll.io> * fix: is_init continue if nil=1 * refactor bitstring table to separate out bitstrings of different len --------- Signed-off-by: noelwei <fan@scroll.io> Co-authored-by: noelwei <fan@scroll.io> Co-authored-by: Ray Gao <qg2153@columbia.edu> * fix: handle padding in blob-data and batch-data configs (integration tests OK) --------- Signed-off-by: noelwei <fan@scroll.io> Co-authored-by: Rohit Narurkar <rohit.narurkar@proton.me> Co-authored-by: Ho <noel.wei@gmail.com> Co-authored-by: noelwei <fan@scroll.io>
- Loading branch information
1 parent
470ec80
commit dae1a7a
Showing
312 changed files
with
7,945 additions
and
3,074 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.