Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

degree > 1 main constraint sumcheck implementation #107 #108

Merged
merged 2 commits into from
Aug 9, 2024

Conversation

hero78119
Copy link
Collaborator

To address #107

@hero78119 hero78119 marked this pull request as draft August 8, 2024 16:47
@hero78119 hero78119 marked this pull request as ready for review August 9, 2024 02:49
@hero78119
Copy link
Collaborator Author

will merge and combine with #91 to review together

@hero78119 hero78119 merged commit 9885767 into feat/new_zkvm_design Aug 9, 2024
6 of 8 checks passed
kunxian-xia pushed a commit that referenced this pull request Aug 23, 2024
* optimize sumcheck algo

circuit witness: direct witness on mle

devirgo style on phase1_output

* initial version for new zkVM design

* riscv add prototype implementation

* add new zkVM prover

* new package ceno_zkvm

* record witness generation

* add transcript

* add verifier

* code cleanup

* rename expression

* prover record_r/record_w sumcheck

* main sel sumcheck proof/verify

* tower product witness inference

* tower product sumcheck prove/verify

* chores: fix tower sumcheck witness length error and clean up

* verify record and zero expression

* tower sumcheck prove/verify pass

* WIP test main sel prove/verify

* add benchmark

* chores: interleaving with default value

* main constraint sumcheck prove/verify pass

* chores: mock witness

* main constraint sumcheck verify final claim assertion pass

* restructure ceno_zkvm package

* refine expression format

* wip lookup

* lookup in logup implemetation with integration test pass

* chores: code cosmetics

* optimize with 2-stage sumcheck #103

* chores: refine virtual polys naming

* fix proper ts and pc counting

* try sumcheck bench

* refine global state in riscv

* degree > 1 main constraint sumcheck implementation #107 (#108)

* monomial expression to virtual poly

* degree > 1 sumcheck batched with main constraint

* succint selector evaluation

* refine succint selector evaluation formula and documentation

* wip fix interleaving edge case

* deal with interleaving_mles instance = 1 case

* chores: code cosmetics and address review comments

* fix logup padding with chip record challenge

* riscv opcode type & combine add/sub opcode & dependency trim

* ci whitelist ceno_zkvm lint/clippy

* address review comments and naming cosmetics

* remove unnessesary to_vec operation

* tower verifier logup p(x) constant check

* cleanup and hide thread-based logic

* soundness fix: derive new sumcheck batched challenge for each round

* fix sel evaluation point and add TODO check

* fix sumcheck batched challenge deriving order

* chore: rename pc step size & fine tune project structure

* fix lint error
kunxian-xia pushed a commit that referenced this pull request Aug 23, 2024
* optimize sumcheck algo

circuit witness: direct witness on mle

devirgo style on phase1_output

* temporarily exclude singer-pro from default workspace members

* fux build error in mpcs

* [Experiment] new zkVM design (#91)

* optimize sumcheck algo

circuit witness: direct witness on mle

devirgo style on phase1_output

* initial version for new zkVM design

* riscv add prototype implementation

* add new zkVM prover

* new package ceno_zkvm

* record witness generation

* add transcript

* add verifier

* code cleanup

* rename expression

* prover record_r/record_w sumcheck

* main sel sumcheck proof/verify

* tower product witness inference

* tower product sumcheck prove/verify

* chores: fix tower sumcheck witness length error and clean up

* verify record and zero expression

* tower sumcheck prove/verify pass

* WIP test main sel prove/verify

* add benchmark

* chores: interleaving with default value

* main constraint sumcheck prove/verify pass

* chores: mock witness

* main constraint sumcheck verify final claim assertion pass

* restructure ceno_zkvm package

* refine expression format

* wip lookup

* lookup in logup implemetation with integration test pass

* chores: code cosmetics

* optimize with 2-stage sumcheck #103

* chores: refine virtual polys naming

* fix proper ts and pc counting

* try sumcheck bench

* refine global state in riscv

* degree > 1 main constraint sumcheck implementation #107 (#108)

* monomial expression to virtual poly

* degree > 1 sumcheck batched with main constraint

* succint selector evaluation

* refine succint selector evaluation formula and documentation

* wip fix interleaving edge case

* deal with interleaving_mles instance = 1 case

* chores: code cosmetics and address review comments

* fix logup padding with chip record challenge

* riscv opcode type & combine add/sub opcode & dependency trim

* ci whitelist ceno_zkvm lint/clippy

* address review comments and naming cosmetics

* remove unnessesary to_vec operation

* tower verifier logup p(x) constant check

* cleanup and hide thread-based logic

* soundness fix: derive new sumcheck batched challenge for each round

* fix sel evaluation point and add TODO check

* fix sumcheck batched challenge deriving order

* chore: rename pc step size & fine tune project structure

* fix lint error
kunxian-xia pushed a commit that referenced this pull request Aug 27, 2024
* optimize sumcheck algo

circuit witness: direct witness on mle

devirgo style on phase1_output

* initial version for new zkVM design

* riscv add prototype implementation

* add new zkVM prover

* new package ceno_zkvm

* record witness generation

* add transcript

* add verifier

* code cleanup

* rename expression

* prover record_r/record_w sumcheck

* main sel sumcheck proof/verify

* tower product witness inference

* tower product sumcheck prove/verify

* chores: fix tower sumcheck witness length error and clean up

* verify record and zero expression

* tower sumcheck prove/verify pass

* WIP test main sel prove/verify

* add benchmark

* chores: interleaving with default value

* main constraint sumcheck prove/verify pass

* chores: mock witness

* main constraint sumcheck verify final claim assertion pass

* restructure ceno_zkvm package

* refine expression format

* wip lookup

* lookup in logup implemetation with integration test pass

* chores: code cosmetics

* optimize with 2-stage sumcheck #103

* chores: refine virtual polys naming

* fix proper ts and pc counting

* try sumcheck bench

* refine global state in riscv

* degree > 1 main constraint sumcheck implementation #107 (#108)

* monomial expression to virtual poly

* degree > 1 sumcheck batched with main constraint

* succint selector evaluation

* refine succint selector evaluation formula and documentation

* wip fix interleaving edge case

* deal with interleaving_mles instance = 1 case

* chores: code cosmetics and address review comments

* fix logup padding with chip record challenge

* riscv opcode type & combine add/sub opcode & dependency trim

* ci whitelist ceno_zkvm lint/clippy

* address review comments and naming cosmetics

* remove unnessesary to_vec operation

* deal with interleaving_mles instance = 1 case

* support add/mul

* adding test cases for UInt::add

* refactor add and adding add_const test cases

* adding UInt::mul test cases and refine UInt.expr()

* refine test cases

* minor refinement

* tower verifier logup p(x) constant check

* cleanup and hide thread-based logic

* support sub logic in addsub gadget

* add range checks for witIns and address some review feedback

* soundness fix: derive new sumcheck batched challenge for each round

* fix sel evaluation point and add TODO check

* fix sumcheck batched challenge deriving order

* add overflow constraint and support expr -> witIn under mul operation

* chore: rename pc step size & fine tune project structure

* assert decomposed constant equals original value

* remove IS_OVERFLOW flag

* test: fix wit_in of the operation result in testing

* add is_None check in create_carry_witin

* add _unsafe version and some cleanup

* remove computed_outcome as review feedback

* remove zombie witnesses

* generalize 0xFFFF

* refactor range check function to  assert_ux

* fixing review feedback

* fixing lint

* move uint to upper layer to fix lint error

* fix for review feedback, rename create_witin and refine comment

* remove unnecessary range check

---------

Co-authored-by: sm.wu <[email protected]>
hero78119 added a commit that referenced this pull request Sep 30, 2024
* optimize sumcheck algo

circuit witness: direct witness on mle

devirgo style on phase1_output

* temporarily exclude singer-pro from default workspace members

* fux build error in mpcs

* [Experiment] new zkVM design (#91)

* optimize sumcheck algo

circuit witness: direct witness on mle

devirgo style on phase1_output

* initial version for new zkVM design

* riscv add prototype implementation

* add new zkVM prover

* new package ceno_zkvm

* record witness generation

* add transcript

* add verifier

* code cleanup

* rename expression

* prover record_r/record_w sumcheck

* main sel sumcheck proof/verify

* tower product witness inference

* tower product sumcheck prove/verify

* chores: fix tower sumcheck witness length error and clean up

* verify record and zero expression

* tower sumcheck prove/verify pass

* WIP test main sel prove/verify

* add benchmark

* chores: interleaving with default value

* main constraint sumcheck prove/verify pass

* chores: mock witness

* main constraint sumcheck verify final claim assertion pass

* restructure ceno_zkvm package

* refine expression format

* wip lookup

* lookup in logup implemetation with integration test pass

* chores: code cosmetics

* optimize with 2-stage sumcheck #103

* chores: refine virtual polys naming

* fix proper ts and pc counting

* try sumcheck bench

* refine global state in riscv

* degree > 1 main constraint sumcheck implementation #107 (#108)

* monomial expression to virtual poly

* degree > 1 sumcheck batched with main constraint

* succint selector evaluation

* refine succint selector evaluation formula and documentation

* wip fix interleaving edge case

* deal with interleaving_mles instance = 1 case

* chores: code cosmetics and address review comments

* fix logup padding with chip record challenge

* riscv opcode type & combine add/sub opcode & dependency trim

* ci whitelist ceno_zkvm lint/clippy

* address review comments and naming cosmetics

* remove unnessesary to_vec operation

* tower verifier logup p(x) constant check

* cleanup and hide thread-based logic

* soundness fix: derive new sumcheck batched challenge for each round

* fix sel evaluation point and add TODO check

* fix sumcheck batched challenge deriving order

* chore: rename pc step size & fine tune project structure

* fix lint error
hero78119 added a commit that referenced this pull request Sep 30, 2024
* optimize sumcheck algo

circuit witness: direct witness on mle

devirgo style on phase1_output

* initial version for new zkVM design

* riscv add prototype implementation

* add new zkVM prover

* new package ceno_zkvm

* record witness generation

* add transcript

* add verifier

* code cleanup

* rename expression

* prover record_r/record_w sumcheck

* main sel sumcheck proof/verify

* tower product witness inference

* tower product sumcheck prove/verify

* chores: fix tower sumcheck witness length error and clean up

* verify record and zero expression

* tower sumcheck prove/verify pass

* WIP test main sel prove/verify

* add benchmark

* chores: interleaving with default value

* main constraint sumcheck prove/verify pass

* chores: mock witness

* main constraint sumcheck verify final claim assertion pass

* restructure ceno_zkvm package

* refine expression format

* wip lookup

* lookup in logup implemetation with integration test pass

* chores: code cosmetics

* optimize with 2-stage sumcheck #103

* chores: refine virtual polys naming

* fix proper ts and pc counting

* try sumcheck bench

* refine global state in riscv

* degree > 1 main constraint sumcheck implementation #107 (#108)

* monomial expression to virtual poly

* degree > 1 sumcheck batched with main constraint

* succint selector evaluation

* refine succint selector evaluation formula and documentation

* wip fix interleaving edge case

* deal with interleaving_mles instance = 1 case

* chores: code cosmetics and address review comments

* fix logup padding with chip record challenge

* riscv opcode type & combine add/sub opcode & dependency trim

* ci whitelist ceno_zkvm lint/clippy

* address review comments and naming cosmetics

* remove unnessesary to_vec operation

* deal with interleaving_mles instance = 1 case

* support add/mul

* adding test cases for UInt::add

* refactor add and adding add_const test cases

* adding UInt::mul test cases and refine UInt.expr()

* refine test cases

* minor refinement

* tower verifier logup p(x) constant check

* cleanup and hide thread-based logic

* support sub logic in addsub gadget

* add range checks for witIns and address some review feedback

* soundness fix: derive new sumcheck batched challenge for each round

* fix sel evaluation point and add TODO check

* fix sumcheck batched challenge deriving order

* add overflow constraint and support expr -> witIn under mul operation

* chore: rename pc step size & fine tune project structure

* assert decomposed constant equals original value

* remove IS_OVERFLOW flag

* test: fix wit_in of the operation result in testing

* add is_None check in create_carry_witin

* add _unsafe version and some cleanup

* remove computed_outcome as review feedback

* remove zombie witnesses

* generalize 0xFFFF

* refactor range check function to  assert_ux

* fixing review feedback

* fixing lint

* move uint to upper layer to fix lint error

* fix for review feedback, rename create_witin and refine comment

* remove unnecessary range check

---------

Co-authored-by: sm.wu <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant