feat(acir_gen): Use predicates with MemoryOps#2400
Closed
Conversation
…hen generating acir
5 tasks
Contributor
|
Waiting to review this until the other PR on mv/mem-op-predicate is merged |
TomAFrench
requested changes
Aug 22, 2023
Member
TomAFrench
left a comment
There was a problem hiding this comment.
This is currently using a patched ACVM and should not be merged until we've included the changes in a release.
5 tasks
Contributor
|
What is the status of this PR? |
Contributor
Author
|
This PR was originally created to avoid the execution error in ACVM with mem ops and predicates. This should be superseded by #2493. As per #2493 (comment) we should be able to then remove the inclusion of a predicate on the MemoryOp ACIR opcode as well. |
Contributor
Author
|
Superseded by #2553 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Problem*
Resolves #2133
Summary*
The ACVM was missing a predicate as part of MemoryOps, thus we were pushing MemoryOps in ACIR gen without their predicate. This caused memory operations under dynamic predicates to be executed no matter what. This is a bug as we can error out with an index out of bounds for valid execution. The linked issue has a full example of this and I have expanded the
dynamic_index_failuretest:Patches:
Backend branch: noir-lang/acvm-backend-barretenberg#247
ACVM: noir-lang/acvm#503
Documentation
This PR requires documentation updates when merged.
Additional Context
PR Checklist*
cargo fmton default settings.