feat!: new semantic for bit-shifts #9373
Conversation
Changes to Brillig bytecode sizes
🧾 Summary (10% most significant diffs)
Full diff report 👇
|
Changes to number of Brillig opcodes executed
🧾 Summary (10% most significant diffs)
Full diff report 👇
|
|
FYI @noir-lang/developerrelations on Noir doc changes. |
There was a problem hiding this comment.
⚠️ Performance Alert ⚠️
Possible performance regression was detected for benchmark 'Test Suite Duration'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 1.20.
| Benchmark suite | Current: 925d517 | Previous: 4f8dbbc | Ratio |
|---|---|---|---|
test_report_zkpassport_noir-ecdsa_ |
2 s |
1 s |
2 |
This comment was automatically generated by workflow using github-action-benchmark.
CC: @TomAFrench
|
🚀 Deployed on https://689e0dac900f62db5aeffada--noir-docs.netlify.app |
There was a problem hiding this comment.
⚠️ Performance Alert ⚠️
Possible performance regression was detected for benchmark 'Execution Time'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 1.20.
| Benchmark suite | Current: d2200ea | Previous: ee2ac1a | Ratio |
|---|---|---|---|
sha512-100-bytes |
0.142 s |
0.096 s |
1.48 |
This comment was automatically generated by workflow using github-action-benchmark.
CC: @TomAFrench
|
Looks like this is timing out all the debug tests locally |
Strange we're getting such a large regression here as while there's been a few changes to this program it shouldn't result in ~700 new opcodes afaict. Edit: due to the removals above? Edit Edit: We're now doing more runtime signed bitshifts so the overflow checks could be the cause of this. |
There was a problem hiding this comment.
⚠️ Performance Alert ⚠️
Possible performance regression was detected for benchmark 'Compilation Time'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 1.20.
| Benchmark suite | Current: d9ba69c | Previous: ee2ac1a | Ratio |
|---|---|---|---|
semaphore-depth-10 |
0.958 s |
0.759 s |
1.26 |
This comment was automatically generated by workflow using github-action-benchmark.
CC: @TomAFrench
jfecher
left a comment
There was a problem hiding this comment.
LGTM - looks like external repos are failing to build though
Automated pull of nightly from the [noir](https://github.com/noir-lang/noir) programming language, a dependency of Aztec. BEGIN_COMMIT_OVERRIDE chore: restore noir libs in CI (noir-lang/noir#9499) feat!: new semantic for bit-shifts (noir-lang/noir#9373) fix(ssa): Replace side effects with defaults when disabled (noir-lang/noir#9462) fix(ssa): Replace pop from 0-length slice with constraint and defaults (noir-lang/noir#9489) fix: assert types are not mutated in constant folding (noir-lang/noir#9481) fix: remove shadowing in `BoundedVec::any` causing returning false unconditionally (noir-lang/noir#9478) END_COMMIT_OVERRIDE
Automated pull of nightly from the [noir](https://github.com/noir-lang/noir) programming language, a dependency of Aztec. BEGIN_COMMIT_OVERRIDE chore: restore noir libs in CI (noir-lang/noir#9499) feat!: new semantic for bit-shifts (noir-lang/noir#9373) fix(ssa): Replace side effects with defaults when disabled (noir-lang/noir#9462) fix(ssa): Replace pop from 0-length slice with constraint and defaults (noir-lang/noir#9489) fix: assert types are not mutated in constant folding (noir-lang/noir#9481) fix: remove shadowing in `BoundedVec::any` causing returning false unconditionally (noir-lang/noir#9478) END_COMMIT_OVERRIDE
Automated pull of nightly from the [noir](https://github.com/noir-lang/noir) programming language, a dependency of Aztec. BEGIN_COMMIT_OVERRIDE chore: restore noir libs in CI (noir-lang/noir#9499) feat!: new semantic for bit-shifts (noir-lang/noir#9373) fix(ssa): Replace side effects with defaults when disabled (noir-lang/noir#9462) fix(ssa): Replace pop from 0-length slice with constraint and defaults (noir-lang/noir#9489) fix: assert types are not mutated in constant folding (noir-lang/noir#9481) fix: remove shadowing in `BoundedVec::any` causing returning false unconditionally (noir-lang/noir#9478) END_COMMIT_OVERRIDE
Automated pull of nightly from the [noir](https://github.com/noir-lang/noir) programming language, a dependency of Aztec. BEGIN_COMMIT_OVERRIDE chore: restore noir libs in CI (noir-lang/noir#9499) feat!: new semantic for bit-shifts (noir-lang/noir#9373) fix(ssa): Replace side effects with defaults when disabled (noir-lang/noir#9462) fix(ssa): Replace pop from 0-length slice with constraint and defaults (noir-lang/noir#9489) fix: assert types are not mutated in constant folding (noir-lang/noir#9481) fix: remove shadowing in `BoundedVec::any` causing returning false unconditionally (noir-lang/noir#9478) END_COMMIT_OVERRIDE
Description
Problem*
Resolves #9022
Summary*
Bit-shifts now requires that rhs and lhs have the same type (instead of u8 for rhs). This is a breaking change.
If rhs > bit_size of rhs type (or bit_size -1 for signed types), then bit-shift will overflow.
Additional Context
Documentation*
Check one:
PR Checklist*
cargo fmton default settings.