-
Notifications
You must be signed in to change notification settings - Fork 242
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
Arrays of structs passed as parameter are not serialized correctly #1953
Comments
Seems to be resolved with #1917 |
Took at look at the output from ABI encoding vs what the circuit is actually doing and these seem to be the two witness layouts involved.
I'm not sure why ACIR gen is laying out the witnesses in this order. It seems really odd compared to what the ABI is doing. |
@jfecher why do we interlace all of the structs' fields in an array of structs in ACIR gen? |
I think it's because the SSA/ACIR expects array of structs to struct of arrays conversion but it's no longer done when generating the ABI |
And I think the PR I mentioned fixes it because it removes that conversion from the SSA |
@TomAFrench as @sirasistant mentioned, I believe it is to match the Array of structs -> struct of arrays conversion that is performed during monomorphization. I'd like to remove this but can't until we remove the old ssa code which doesn't support arrays of structs. @sirasistant do you know if #1917 still exhibits the issue if you don't pass the |
@jfecher old ssa has a catch for this apparently:
|
Ah, right. Since the old SSA crashes either way I think we can consider this fixed once #1917 is merged then. |
Closing as #1917 has been merged |
Aim
Validating this program
Expected Behavior
Should verify with this Prover.toml
Bug
The initial witness is not serialized correctly for the format that ACIR expects:
To Reproduce
Installation Method
None
Nargo Version
No response
Additional Context
No response
Would you like to submit a PR for this Issue?
No
Support Needs
No response
The text was updated successfully, but these errors were encountered: