You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In noir/acir, Expression is a struct that holds an arbitrary number of simple quadratic and linear terms. On the bberg-acir side, it has the same form but there is an implicit assumption that it will contain a max of 1 quadratic term and 3 linear terms since this is all that can be accommodated by poly_tuple (i.e. the input to a width-3 arithmetic gate). In practice, noir seems to exclusively produce Expressions of this form but its not clear that there is any structural barrier that prevents other sizes. It may just be another "leakage" of bberg structure into noir. (Indeed, we could already accommodate 1 quadratic and 4 linear terms using the Ultra (width-4) arithmetic gate, but this is not done).
The text was updated successfully, but these errors were encountered:
@TomAFrench Thanks for clarifying. This was meant to be a comment more on the barretenberg side. If noir were to suddenly start sending an Expression with more than 1 quadratic term, there is nothing on the barretenberg side that would prevent much less alert us to that issue. (Except for the assert statement added in this PR). I understand why the Expression on the noir side needs to be more general, but it seems that the analogous container on the bberg side should be more restrictive.
In noir/acir,
Expression
is a struct that holds an arbitrary number of simple quadratic and linear terms. On the bberg-acir side, it has the same form but there is an implicit assumption that it will contain a max of 1 quadratic term and 3 linear terms since this is all that can be accommodated by poly_tuple (i.e. the input to a width-3 arithmetic gate). In practice, noir seems to exclusively produceExpression
s of this form but its not clear that there is any structural barrier that prevents other sizes. It may just be another "leakage" of bberg structure into noir. (Indeed, we could already accommodate 1 quadratic and 4 linear terms using the Ultra (width-4) arithmetic gate, but this is not done).The text was updated successfully, but these errors were encountered: