forked from noir-lang/noir
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(ssa): Check if result of array set is used in value of another ar…
…ray set (noir-lang#6197) # Description ## Problem\* Resolves <!-- Link to GitHub Issue --> ## Summary\* Fix for failure in the `test_barycentric` of the `blob` lib in `noir-protocol-circuits`. The test now passes when Brillig's `MAX_STACK_SIZE` is increased to 32k. I included an additional map to track whether an array set result was used as a value in another array set. We can not allow for inner nested array sets to be mutable across blocks as the full nested array may be used in another block. We could add additional logic to check whether the parent array set will be marked mutable, but this seems overly complex for little benefit at the moment as this fix showed a quite small size regression. ## Additional Context ## Documentation\* Check one: - [X] No documentation needed. - [ ] Documentation included in this PR. - [ ] **[For Experimental Features]** Documentation to be submitted in a separate PR. # PR Checklist\* - [X] I have tested the changes locally. - [X] I have formatted the changes with [Prettier](https://prettier.io/) and/or `cargo fmt` on default settings.
- Loading branch information
Showing
1 changed file
with
57 additions
and
34 deletions.
There are no files selected for viewing
This file contains 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