Skip to content
This repository was archived by the owner on Apr 9, 2024. It is now read-only.

feat(brillig): Support integers which fit inside a FieldElement#403

Merged
kevaundray merged 5 commits intomasterfrom
gd/bigger_integer
Jul 20, 2023
Merged

feat(brillig): Support integers which fit inside a FieldElement#403
kevaundray merged 5 commits intomasterfrom
gd/bigger_integer

Conversation

@guipublic
Copy link
Contributor

Description

Problem*

Brillig was limited to 128 bits for integer operations, which prevent to use brillig to replace the quotient directive (which itself replace the truncate directive which requires more than 128 bits)

Related to noir-lang/noir#1766

Summary*

We convert field elements to big integers and perform the operations on the big integers, using the provided bit size

Additional Context

PR Checklist*

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

@TomAFrench TomAFrench changed the title chore(brillig): support integers which fit inside a field element feat(brillig): support integers which fit inside a FieldElement Jul 11, 2023
@TomAFrench TomAFrench changed the title feat(brillig): support integers which fit inside a FieldElement feat(brillig): Support integers which fit inside a FieldElement Jul 11, 2023
@TomAFrench
Copy link
Member

Looks sensible to me. Any reason to not merge this at the moment?

@kevaundray kevaundray self-requested a review July 15, 2023 10:05
Copy link
Contributor

@sirasistant sirasistant left a comment

Choose a reason for hiding this comment

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

LGTM

@kevaundray kevaundray added this pull request to the merge queue Jul 20, 2023
Merged via the queue into master with commit f992412 Jul 20, 2023
@kevaundray kevaundray mentioned this pull request Jul 20, 2023
@TomAFrench TomAFrench deleted the gd/bigger_integer branch August 2, 2023 17:45
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants