Skip to content

fix: check "negate with overflow" in comptime code + allow u1 to be used in comptime code#8969

Merged
TomAFrench merged 7 commits intomasterfrom
ab/comptime-negate-with-overflow
Jun 20, 2025
Merged

fix: check "negate with overflow" in comptime code + allow u1 to be used in comptime code#8969
TomAFrench merged 7 commits intomasterfrom
ab/comptime-negate-with-overflow

Conversation

@asterite
Copy link
Copy Markdown
Collaborator

Description

Problem

Resolves #8870

Summary

Additional Context

Documentation

Check one:

  • No documentation needed.
  • Documentation included in this PR.
  • [For Experimental Features] Documentation to be submitted in a separate PR.

PR Checklist

  • I have tested the changes locally.
  • I have formatted the changes with Prettier and/or cargo fmt on default settings.

Copy link
Copy Markdown
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ 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: 0be1f7b Previous: 71ab596 Ratio
rollup-merge 0.004 s 0.003 s 1.33

This comment was automatically generated by workflow using github-action-benchmark.

CC: @TomAFrench

@asterite asterite requested a review from a team June 18, 2025 17:36
@asterite asterite changed the title fix: check "negate with overflow" in comptime code fix: check "negate with overflow" in comptime code + allow u1 to be used in comptime code Jun 18, 2025
@TomAFrench TomAFrench enabled auto-merge June 20, 2025 13:52
@TomAFrench TomAFrench added this pull request to the merge queue Jun 20, 2025
Merged via the queue into master with commit 256c678 Jun 20, 2025
118 checks passed
@TomAFrench TomAFrench deleted the ab/comptime-negate-with-overflow branch June 20, 2025 14:39
github-merge-queue bot pushed a commit to AztecProtocol/aztec-packages that referenced this pull request Jun 23, 2025
Automated pull of nightly from the
[noir](https://github.com/noir-lang/noir) programming language, a
dependency of Aztec.
BEGIN_COMMIT_OVERRIDE
fix: increment reference counts when deduplicating calls which return
arrays (noir-lang/noir#8757)
fix: Add a aliased check for last stores
(noir-lang/noir#8955)
fix(LICM): Consider negative loop bounds before hoisting `div <const>
<induction-var>` (noir-lang/noir#8986)
fix: check "negate with overflow" in comptime code + allow u1 to be used
in comptime code (noir-lang/noir#8969)
fix: better package name validation and error messages for nargo
new/init (noir-lang/noir#8978)
feat(fuzz): Add comptime_vs_brillig_direct target
(noir-lang/noir#8924)
fix(expand): show references to ModuleDefId recursing on parents
(noir-lang/noir#8977)
feat(ssa_fuzzer): loops + signed
(noir-lang/noir#8881)
fix(fuzz): Do not take a mutable reference over immutable vars which
contain a mutable ref (noir-lang/noir#8971)
fix(fuzz): Avoid negating `i8::MIN` into `i8::MAX+1` which won't compile
(noir-lang/noir#8972)
END_COMMIT_OVERRIDE

---------

Co-authored-by: AztecBot <[email protected]>
Co-authored-by: Tom French <[email protected]>
github-merge-queue bot pushed a commit to AztecProtocol/aztec-packages that referenced this pull request Jun 23, 2025
Automated pull of nightly from the
[noir](https://github.com/noir-lang/noir) programming language, a
dependency of Aztec.
BEGIN_COMMIT_OVERRIDE
fix: increment reference counts when deduplicating calls which return
arrays (noir-lang/noir#8757)
fix: Add a aliased check for last stores
(noir-lang/noir#8955)
fix(LICM): Consider negative loop bounds before hoisting `div <const>
<induction-var>` (noir-lang/noir#8986)
fix: check "negate with overflow" in comptime code + allow u1 to be used
in comptime code (noir-lang/noir#8969)
fix: better package name validation and error messages for nargo
new/init (noir-lang/noir#8978)
feat(fuzz): Add comptime_vs_brillig_direct target
(noir-lang/noir#8924)
fix(expand): show references to ModuleDefId recursing on parents
(noir-lang/noir#8977)
feat(ssa_fuzzer): loops + signed
(noir-lang/noir#8881)
fix(fuzz): Do not take a mutable reference over immutable vars which
contain a mutable ref (noir-lang/noir#8971)
fix(fuzz): Avoid negating `i8::MIN` into `i8::MAX+1` which won't compile
(noir-lang/noir#8972)
END_COMMIT_OVERRIDE

---------

Co-authored-by: AztecBot <[email protected]>
Co-authored-by: Tom French <[email protected]>
github-merge-queue bot pushed a commit to AztecProtocol/aztec-packages that referenced this pull request Jun 23, 2025
Automated pull of nightly from the
[noir](https://github.com/noir-lang/noir) programming language, a
dependency of Aztec.
BEGIN_COMMIT_OVERRIDE
fix: increment reference counts when deduplicating calls which return
arrays (noir-lang/noir#8757)
fix: Add a aliased check for last stores
(noir-lang/noir#8955)
fix(LICM): Consider negative loop bounds before hoisting `div <const>
<induction-var>` (noir-lang/noir#8986)
fix: check "negate with overflow" in comptime code + allow u1 to be used
in comptime code (noir-lang/noir#8969)
fix: better package name validation and error messages for nargo
new/init (noir-lang/noir#8978)
feat(fuzz): Add comptime_vs_brillig_direct target
(noir-lang/noir#8924)
fix(expand): show references to ModuleDefId recursing on parents
(noir-lang/noir#8977)
feat(ssa_fuzzer): loops + signed
(noir-lang/noir#8881)
fix(fuzz): Do not take a mutable reference over immutable vars which
contain a mutable ref (noir-lang/noir#8971)
fix(fuzz): Avoid negating `i8::MIN` into `i8::MAX+1` which won't compile
(noir-lang/noir#8972)
END_COMMIT_OVERRIDE

---------

Co-authored-by: AztecBot <[email protected]>
Co-authored-by: Tom French <[email protected]>
github-merge-queue bot pushed a commit to AztecProtocol/aztec-packages that referenced this pull request Jun 23, 2025
Automated pull of nightly from the
[noir](https://github.com/noir-lang/noir) programming language, a
dependency of Aztec.
BEGIN_COMMIT_OVERRIDE
fix: increment reference counts when deduplicating calls which return
arrays (noir-lang/noir#8757)
fix: Add a aliased check for last stores
(noir-lang/noir#8955)
fix(LICM): Consider negative loop bounds before hoisting `div <const>
<induction-var>` (noir-lang/noir#8986)
fix: check "negate with overflow" in comptime code + allow u1 to be used
in comptime code (noir-lang/noir#8969)
fix: better package name validation and error messages for nargo
new/init (noir-lang/noir#8978)
feat(fuzz): Add comptime_vs_brillig_direct target
(noir-lang/noir#8924)
fix(expand): show references to ModuleDefId recursing on parents
(noir-lang/noir#8977)
feat(ssa_fuzzer): loops + signed
(noir-lang/noir#8881)
fix(fuzz): Do not take a mutable reference over immutable vars which
contain a mutable ref (noir-lang/noir#8971)
fix(fuzz): Avoid negating `i8::MIN` into `i8::MAX+1` which won't compile
(noir-lang/noir#8972)
END_COMMIT_OVERRIDE

---------

Co-authored-by: AztecBot <[email protected]>
Co-authored-by: Tom French <[email protected]>
danielntmd pushed a commit to danielntmd/aztec-packages that referenced this pull request Jul 16, 2025
Automated pull of nightly from the
[noir](https://github.com/noir-lang/noir) programming language, a
dependency of Aztec.
BEGIN_COMMIT_OVERRIDE
fix: increment reference counts when deduplicating calls which return
arrays (noir-lang/noir#8757)
fix: Add a aliased check for last stores
(noir-lang/noir#8955)
fix(LICM): Consider negative loop bounds before hoisting `div <const>
<induction-var>` (noir-lang/noir#8986)
fix: check "negate with overflow" in comptime code + allow u1 to be used
in comptime code (noir-lang/noir#8969)
fix: better package name validation and error messages for nargo
new/init (noir-lang/noir#8978)
feat(fuzz): Add comptime_vs_brillig_direct target
(noir-lang/noir#8924)
fix(expand): show references to ModuleDefId recursing on parents
(noir-lang/noir#8977)
feat(ssa_fuzzer): loops + signed
(noir-lang/noir#8881)
fix(fuzz): Do not take a mutable reference over immutable vars which
contain a mutable ref (noir-lang/noir#8971)
fix(fuzz): Avoid negating `i8::MIN` into `i8::MAX+1` which won't compile
(noir-lang/noir#8972)
END_COMMIT_OVERRIDE

---------

Co-authored-by: AztecBot <[email protected]>
Co-authored-by: Tom French <[email protected]>
AztecBot added a commit to AztecProtocol/barretenberg that referenced this pull request Dec 3, 2025
Automated pull of nightly from the
[noir](https://github.com/noir-lang/noir) programming language, a
dependency of Aztec.
BEGIN_COMMIT_OVERRIDE
fix: increment reference counts when deduplicating calls which return
arrays (noir-lang/noir#8757)
fix: Add a aliased check for last stores
(noir-lang/noir#8955)
fix(LICM): Consider negative loop bounds before hoisting `div <const>
<induction-var>` (noir-lang/noir#8986)
fix: check "negate with overflow" in comptime code + allow u1 to be used
in comptime code (noir-lang/noir#8969)
fix: better package name validation and error messages for nargo
new/init (noir-lang/noir#8978)
feat(fuzz): Add comptime_vs_brillig_direct target
(noir-lang/noir#8924)
fix(expand): show references to ModuleDefId recursing on parents
(noir-lang/noir#8977)
feat(ssa_fuzzer): loops + signed
(noir-lang/noir#8881)
fix(fuzz): Do not take a mutable reference over immutable vars which
contain a mutable ref (noir-lang/noir#8971)
fix(fuzz): Avoid negating `i8::MIN` into `i8::MAX+1` which won't compile
(noir-lang/noir#8972)
END_COMMIT_OVERRIDE

---------

Co-authored-by: AztecBot <[email protected]>
Co-authored-by: Tom French <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Comptime crash: -128 as i8

3 participants