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

Refactor SetTableAddrType #573

Closed
naure opened this issue Nov 7, 2024 · 4 comments
Closed

Refactor SetTableAddrType #573

naure opened this issue Nov 7, 2024 · 4 comments
Assignees
Labels
cleanup Refactors, simplifications, hindsight 20/20 tasks.

Comments

@naure
Copy link
Collaborator

naure commented Nov 7, 2024

While adding memory and PI features, there has been some leakage of frontend concepts into the backend, which should only know about math, not VMs.

Some pointer: SetTableAddrType::DynamicAddr

This could be refactored into a new type of polynomial type, similar to Constant, Fixed, etc. Let’s say Linear.
Then the circuits can use Linear columns to do for example address ranges.

Another problem is that this table specification is needed during circuit "construction", but it belongs more logically and conveniently to the fixed table generation phase. I don’t know how to fix that one yet, though. (already solved by CircuitBuilder.params)

@naure naure added the cleanup Refactors, simplifications, hindsight 20/20 tasks. label Nov 7, 2024
@naure naure assigned mcalancea and unassigned mcalancea Nov 13, 2024
@naure
Copy link
Collaborator Author

naure commented Nov 18, 2024

More precision here:

In CircuitBuilder, the methods lk_table_record, r_table_record, and w_table_record take an argument table_len or table_spec.len. That information makes it to VerifierKey.cs and is used to determine numbers of rounds.

My claim is that these length could move either some new property of VerifierKey or Proof. It could work the same way as the non-table variants: lk_record, read_record, write_record, or something like num_instances.

@naure
Copy link
Collaborator Author

naure commented Nov 18, 2024

Alternatively, the lengths could stay in CircuitBuilder, but then let the API accept parameters by value like in #587.

@hero78119
Copy link
Collaborator

I raise another issue which is from backend perspective #654
which also related to probably introduce a new type of polynomial to hold meta info of SetTableAddrType.

@naure
Copy link
Collaborator Author

naure commented Nov 29, 2024

Closing in favor of the more precise #654.

@naure naure closed this as completed Nov 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cleanup Refactors, simplifications, hindsight 20/20 tasks.
Projects
None yet
Development

No branches or pull requests

3 participants