Skip to content
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

feat: Sync from noir #7170

Merged
merged 42 commits into from
Jun 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
eea4376
[1 changes] chore: add back Pedersen blackbox functions (revert PR 52…
AztecBot Jun 24, 2024
e93e9a7
chore: apply sync fixes
AztecBot Jun 24, 2024
648d98f
Merge branch 'master' into sync-noir
TomAFrench Jun 24, 2024
e7c780a
chore: fix
TomAFrench Jun 21, 2024
64c3852
chore: restore honk proof test
TomAFrench Jun 21, 2024
99945f9
fix: correct aztec-packages types
TomAFrench Jun 21, 2024
a2b9244
chore: force usage of legacy codepath
TomAFrench Jun 21, 2024
1e0dfbe
chore: update lockfiles
TomAFrench Jun 24, 2024
352ffe1
chore: force legacy codepath
TomAFrench Jun 24, 2024
c2a931c
chore: fix profiler
TomAFrench Jun 24, 2024
88af69a
chore: update yarn.lock
TomAFrench Jun 24, 2024
14247a5
chore: fmt
TomAFrench Jun 24, 2024
47c8877
chore: fmt
TomAFrench Jun 24, 2024
712736f
chore: fix `noir_js_backend_barretenberg`
TomAFrench Jun 24, 2024
34c5dda
chore: fix imports
TomAFrench Jun 24, 2024
a30edce
chore: fmt
TomAFrench Jun 24, 2024
a679e9c
chore: fix stuff
TomAFrench Jun 24, 2024
012c9fa
chore: use-legacy
TomAFrench Jun 24, 2024
a95b4ac
chore: `use-legacy`
TomAFrench Jun 24, 2024
22a2a3f
chore: `use-legacy`
TomAFrench Jun 24, 2024
c32bef7
chore: revert type change
TomAFrench Jun 25, 2024
239ac39
chore: revert some import changes
TomAFrench Jun 25, 2024
7ec2c33
chore: fmt
TomAFrench Jun 25, 2024
f3ca4a0
chore: make fn public
TomAFrench Jun 25, 2024
b5f06e7
Merge branch 'master' into sync-noir
TomAFrench Jun 25, 2024
25aafd0
chore: fix merge
TomAFrench Jun 25, 2024
d0ae6b0
chore: fmt
TomAFrench Jun 25, 2024
a6ba5c6
test: revert constant arrays optimization
TomAFrench Jun 26, 2024
3709df2
Merge branch 'master' into sync-noir
TomAFrench Jun 26, 2024
fb2f6a8
chore: revert removal of flattening optimisation
TomAFrench Jun 26, 2024
f7b6ab5
chore: improve storage stuff
TomAFrench Jun 26, 2024
64f579f
chore: revert some foreign call changes
TomAFrench Jun 26, 2024
70262da
Merge branch 'master' into sync-noir
TomAFrench Jun 26, 2024
8f4cd13
Merge branch 'master' into sync-noir
TomAFrench Jun 26, 2024
7c05ea1
chore: reduce diff
TomAFrench Jun 26, 2024
569083f
Revert "chore: revert some foreign call changes"
TomAFrench Jun 26, 2024
adbc716
Revert "test: revert constant arrays optimization"
TomAFrench Jun 26, 2024
79083b3
Revert "chore: revert removal of flattening optimisation"
TomAFrench Jun 26, 2024
45421bf
Merge branch 'master' into sync-noir
TomAFrench Jun 27, 2024
a81337f
Merge branch 'master' into sync-noir
TomAFrench Jun 27, 2024
69fe2a8
Merge branch 'master' into sync-noir
TomAFrench Jun 27, 2024
ee0c78b
chore: remove no_predicates
TomAFrench Jun 27, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .noir-sync-commit
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2e543b40eb83ef2080e4d8f870f525fadd631099
f2f8ecc833d4725d0829f9c339389c90d1a4fbcd
20 changes: 10 additions & 10 deletions avm-transpiler/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion avm-transpiler/scripts/compile_then_transpile.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ fi
shift # remove the compile arg so we can inject --show-artifact-paths

# Forward all arguments to nargo, tee output to console
artifacts_to_transpile=$($NARGO compile --show-artifact-paths $@ | tee /dev/tty | grep -oP 'Saved contract artifact to: \K.*')
artifacts_to_transpile=$($NARGO compile --use-legacy --show-artifact-paths $@ | tee /dev/tty | grep -oP 'Saved contract artifact to: \K.*')

# NOTE: the output that is teed to /dev/tty will normally not be redirectable by the caller.
# If the script is run via docker, however, the user will see this output on stdout and will be able to redirect.
Expand Down
2 changes: 1 addition & 1 deletion boxes/boxes/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"type": "module",
"main": "./dist/index.js",
"scripts": {
"compile": "cd src/contracts && ${AZTEC_NARGO:-aztec-nargo} compile --silence-warnings",
"compile": "cd src/contracts && ${AZTEC_NARGO:-aztec-nargo} compile --use-legacy --silence-warnings",
"codegen": "${AZTEC_BUILDER:-aztec-builder} codegen src/contracts/target -o artifacts",
"clean": "rm -rf ./dist .tsbuildinfo ./artifacts ./src/contracts/target",
"prep": "yarn clean && yarn compile && yarn codegen",
Expand Down
2 changes: 1 addition & 1 deletion boxes/boxes/vanilla/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"version": "0.1.0",
"type": "module",
"scripts": {
"compile": "cd src/contracts && ${AZTEC_NARGO:-aztec-nargo} compile --silence-warnings",
"compile": "cd src/contracts && ${AZTEC_NARGO:-aztec-nargo} compile --use-legacy --silence-warnings",
"codegen": "${AZTEC_BUILDER:-aztec-builder} codegen src/contracts/target -o artifacts",
"clean": "rm -rf ./dest .tsbuildinfo ./artifacts ./src/contracts/target",
"prep": "yarn clean && yarn compile && yarn codegen && tsc -b",
Expand Down
2 changes: 1 addition & 1 deletion noir-projects/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ RUN ./bootstrap.sh
WORKDIR /usr/src/noir-projects/noir-protocol-circuits
RUN ./bootstrap.sh
WORKDIR /usr/src/noir-projects/aztec-nr
RUN nargo compile --silence-warnings
RUN nargo compile --use-legacy --silence-warnings

FROM scratch
COPY --from=builder /usr/src/noir-projects /usr/src/noir-projects
6 changes: 3 additions & 3 deletions noir-projects/Dockerfile.test
Original file line number Diff line number Diff line change
Expand Up @@ -22,19 +22,19 @@ WORKDIR /usr/src/noir-projects
COPY . .

# Build & test
RUN cd ./noir-protocol-circuits && ./bootstrap.sh && nargo test --silence-warnings
RUN cd ./noir-protocol-circuits && ./bootstrap.sh && nargo test --use-legacy --silence-warnings

RUN cd /usr/src/yarn-project/txe && yarn start & echo $! > /tmp/txe.pid && \
# Wait for TXE to initialize
sleep 5 && \
cd ./noir-contracts && \
# We need to increase the timeout since all tests running in parallel hammer TXE at the same time, and processing slows down leading to timeouts
# The only way we currently have to batch tests is via RAYON_NUM_THREADS, which is not ideal
./bootstrap.sh && NARGO_FOREIGN_CALL_TIMEOUT=300000 nargo test --silence-warnings --oracle-resolver http://localhost:8080 ; \
./bootstrap.sh && NARGO_FOREIGN_CALL_TIMEOUT=300000 nargo test --use-legacy --silence-warnings --oracle-resolver http://localhost:8080 ; \
kill $(cat /tmp/txe.pid)

RUN cd /usr/src/yarn-project/txe && yarn start & echo $! > /tmp/txe.pid && \
# Wait for TXE to initialize
sleep 5 && \
cd ./aztec-nr && \
nargo test --silence-warnings --oracle-resolver http://localhost:8080
nargo test --use-legacy --silence-warnings --oracle-resolver http://localhost:8080
4 changes: 2 additions & 2 deletions noir-projects/Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ test:
RUN cd /usr/src/yarn-project/txe && yarn start & echo $! > /tmp/txe.pid && \
# Wait for TXE to initialize
sleep 5 && \
cd /usr/src/noir-projects/aztec-nr && nargo test --silence-warnings --oracle-resolver http://localhost:8080 ; \
cd /usr/src/noir-projects/aztec-nr && nargo test --use-legacy --silence-warnings --oracle-resolver http://localhost:8080 ; \
kill $(cat /tmp/txe.pid)

RUN cd /usr/src/yarn-project/txe && yarn start & echo $! > /tmp/txe.pid && \
Expand All @@ -61,7 +61,7 @@ test:
cd /usr/src/noir-projects/noir-contracts && \
# We need to increase the timeout since all tests running in parallel hammer TXE at the same time and processing slows down, leading to timeouts
# The only way we currently have to batch tests is via RAYON_NUM_THREADS, which is not ideal
NARGO_FOREIGN_CALL_TIMEOUT=300000 nargo test --silence-warnings --oracle-resolver http://localhost:8080 ; \
NARGO_FOREIGN_CALL_TIMEOUT=300000 nargo test --use-legacy --silence-warnings --oracle-resolver http://localhost:8080 ; \
kill $(cat /tmp/txe.pid)

format:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ struct UnconstrainedContext {
}

impl UnconstrainedContext {
fn new() -> Self {
unconstrained fn new() -> Self {
// We could call these oracles on the getters instead of at creation, which makes sense given that they might
// not even be accessed. However any performance gains are minimal, and we'd rather fail early if a user
// incorrectly attempts to create an UnconstrainedContext in an environment in which these oracles are not
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ unconstrained fn get_contract_instance_internal(address: AztecAddress) -> [Field
get_contract_instance_oracle(address)
}

unconstrained fn get_contract_instance_internal_avm(address: AztecAddress) -> [Field; CONTRACT_INSTANCE_LENGTH + 1] {
unconstrained pub fn get_contract_instance_internal_avm(address: AztecAddress) -> [Field; CONTRACT_INSTANCE_LENGTH + 1] {
get_contract_instance_oracle_avm(address)
}

Expand Down
2 changes: 1 addition & 1 deletion noir-projects/noir-contracts/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ fi

echo "Compiling contracts..."
NARGO=${NARGO:-../../noir/noir-repo/target/release/nargo}
$NARGO compile --silence-warnings
$NARGO compile --silence-warnings --use-legacy

echo "Transpiling contracts..."
scripts/transpile.sh
2 changes: 1 addition & 1 deletion noir-projects/noir-protocol-circuits/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ node ./index.js

echo "Compiling protocol circuits..."
NARGO=${NARGO:-../../noir/noir-repo/target/release/nargo}
$NARGO compile --silence-warnings
$NARGO compile --silence-warnings --use-legacy
4 changes: 2 additions & 2 deletions noir/noir-repo/.release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
".": "0.30.0",
"acvm-repo": "0.46.0"
".": "0.31.0",
"acvm-repo": "0.47.0"
}
Loading
Loading