fix: add exclusive constraint for Miller loop and Final exp masks #174
+830
−816
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.
This PR fixes LA audit Issue J.
We didn't have constraint which required
ToMillerLoopCircuitMask
andToFinalExpCircuitMask
to be exclusive. The recommendation was to check that they are exclusive and sum equals toECPair.IsActive
.However, I couldn't add this constraint as
ECPair.IsActive
may also hold for G2 membership data. I added additionalECPair.UnalignedPairingData.IsActive
column and corresponding constraints to ensure that only G2 membership data or pairing data submodules are active at a time.Additionally, I added constraints to ensure the IsComputed/IsPulling columns are only set when the corresponding submodules were active. This allowed to remove previous explicit binary constraints as they are already checked in
common_constraints
package.Finally, updated the tests to check that the newly added
UnalignedPairingData.IsActive
column is correctly computed.NB! This PR depends on #173 (which depends on #172). After the previous PRs are merged then update the base branch for this PR to main.
Checklist