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

Joinsplit refactor / review? #348

Open
dtebbs opened this issue Jan 25, 2021 · 0 comments
Open

Joinsplit refactor / review? #348

dtebbs opened this issue Jan 25, 2021 · 0 comments
Labels
arithmetic-circuit/R1CS Task related to the R1CS programs c++ Task related to the c++ part of the code base code-quality Task related to the code quality (refactor, enhancements etc.)

Comments

@dtebbs
Copy link
Contributor

dtebbs commented Jan 25, 2021

Further to #290, it could be valuable to review the joinsplit code and potentially refactor it into more maintainable blocks (it is currently approx ~620 lines with ~225 lines in the constructor. For example, a joinsplit_public_data_variable object / gadget.

It could also be worth checking for variables that are being unncessarily allocated (often as a result of limitations of libsnark). One example is the ZERO variable, which seems to be required as a consequence of libsnark::block_variable supporting only libsnark::pb_variable_array. (If libsnark::block_variable could be refactored to use libsnark::pb_linear_combination_array, it could handle constants without needing any further variables - there may be other examples).

@AntoineRondelet AntoineRondelet added arithmetic-circuit/R1CS Task related to the R1CS programs code-quality Task related to the code quality (refactor, enhancements etc.) c++ Task related to the c++ part of the code base labels Feb 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
arithmetic-circuit/R1CS Task related to the R1CS programs c++ Task related to the c++ part of the code base code-quality Task related to the code quality (refactor, enhancements etc.)
Projects
None yet
Development

No branches or pull requests

2 participants