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

Consolidate evaluators for AlgebraicExpression #2197

Open
georgwiese opened this issue Dec 4, 2024 · 0 comments
Open

Consolidate evaluators for AlgebraicExpression #2197

georgwiese opened this issue Dec 4, 2024 · 0 comments

Comments

@georgwiese
Copy link
Collaborator

We currently have various places where we implement evaluating AlgebraicExpression. For example, there is one for each backend (e.g. Plonky3, Halo2, Stwo). Also, #2194 adds an ExpressionEvaluator that is used by the MockBackend and soon by the fast bus witgen as well (#2191).

I think we should consolidate them into one evaluator (could be a generalization of the ExpressionEvaluator mentioned above, see this comment). In addition to the current features (e.g. caching of intermediates), we should also add benchmarks and optimize performance.

Some ideas possible performance improvements:

  • Use ColumnMap (a wrapper around Vec) instead of BTreeMap to store columns (the trace and the intermediates cache)
  • Short-circuit multiplications by 0
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

No branches or pull requests

1 participant