-
Notifications
You must be signed in to change notification settings - Fork 268
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
public-vm(aztec-nr): Add oracles and context for AVM opcodes #4313
Labels
C-avm
Component: AVM related tickets (aka public VM)
Comments
Maddiaa0
changed the title
public-vm(aztec-nr): Add oracles for AVM opcodes
public-vm(aztec-nr): Add oracles and context for AVM opcodes
Jan 30, 2024
This was referenced Feb 5, 2024
Maddiaa0
added a commit
that referenced
this issue
Feb 5, 2024
Maddiaa0
added a commit
that referenced
this issue
Feb 6, 2024
AztecBot
pushed a commit
to AztecProtocol/barretenberg
that referenced
this issue
Feb 6, 2024
AztecBot
pushed a commit
to AztecProtocol/aztec-nr
that referenced
this issue
Feb 6, 2024
AztecBot
pushed a commit
to AztecProtocol/aztec-nr
that referenced
this issue
Feb 6, 2024
TomAFrench
pushed a commit
that referenced
this issue
Feb 7, 2024
TomAFrench
pushed a commit
that referenced
this issue
Feb 7, 2024
michaelelliot
pushed a commit
to Swoir/noir_rs
that referenced
this issue
Feb 28, 2024
michaelelliot
pushed a commit
to Swoir/noir_rs
that referenced
this issue
Feb 28, 2024
This was referenced Mar 8, 2024
fcarreiro
added a commit
that referenced
this issue
Mar 11, 2024
This PR enables the stack of 6 PRs on top. \ While working on external calls, we came across several problems with Brillig. I made some changes to fix them. Some Brillig changes: * **Truncation**: Brillig was using AND of Fields (actually, AND on Ints of 254 bits). This is not supported by the VM. Truncation was changed to be done without ANDing, and using `CAST` instead, which truncates to the required bit size. * **Array.get**/**Array.set**: Calculation of the `arrayBase+index` was done using field arithmetic (or field sizes). Now it's done using ints. * **Reference counting**: Checking `refCount==1` was done using field arithmetic (or field sizes). Now it's done with ints. These changes seem to solve all the comparison w/different bit sizes, and unexpected uses of field arithmetic. (That we've found with the current test contract). NOTE: I had to recreate the contract snapshots with `yarn workspace @aztec/protocol-contracts test -u`, then modify * noir-projects/noir-contracts/contracts/app_subscription_contract/src/main.nr * noir-projects/noir-contracts/contracts/fpc_contract/src/main.nr Relates to #4313, #4127.
fcarreiro
added a commit
that referenced
this issue
Mar 11, 2024
fcarreiro
added a commit
that referenced
this issue
Mar 11, 2024
fcarreiro
added a commit
that referenced
this issue
Mar 11, 2024
superstar0402
added a commit
to superstar0402/aztec-nr
that referenced
this issue
Aug 16, 2024
superstar0402
added a commit
to superstar0402/aztec-nr
that referenced
this issue
Aug 16, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Overview
The avm transpiler converts instances of brillig bytecode into avm bytecode, oracle calls in brillig are represented as
foreign_call("oracle_name")
. These are then swapped out for the avm opcode that gets the particular value.Public calls have their own context for reading in such values, reading in global variables, or getting note externally
We want to create an avm context that will enable the transpiler to insert the correct opcodes for fetching environment getters etc.
The text was updated successfully, but these errors were encountered: