-
Notifications
You must be signed in to change notification settings - Fork 189
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: skip emission of brillig calls which will never be executed (#5314)
# Description ## Problem\* Pulls across fix made in sync PR at AztecProtocol/aztec-packages@e39be3d ## Summary\* For some reason in the `noir-contracts` workspace, we're emitting a _lot_ (100+ MB worth) of brillig call opcodes which have their predicate hardcoded to zero (i.e. they will never actually be executed). This PR adds a check before we emit a brillig call opcode to see if the predicate is zero and, if so, we skip it and zero out all the outputs at compile time. ## 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
1 parent
7689d59
commit b859ef9
Showing
2 changed files
with
43 additions
and
3 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
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