From bcabf1799aa1cd3e93020b93f8b015502cf60e4b Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 09:09:16 -0300 Subject: [PATCH 01/13] chore: Increase functions per contract from 16 to 32 --- circuits/cpp/src/aztec3/constants.hpp | 2 +- l1-contracts/src/core/libraries/ConstantsGen.sol | 2 +- yarn-project/aztec-nr/aztec/src/constants_gen.nr | 2 +- yarn-project/circuits.js/src/constants.gen.ts | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/circuits/cpp/src/aztec3/constants.hpp b/circuits/cpp/src/aztec3/constants.hpp index 39062de3b55..9ecb0b384d8 100644 --- a/circuits/cpp/src/aztec3/constants.hpp +++ b/circuits/cpp/src/aztec3/constants.hpp @@ -98,7 +98,7 @@ constexpr size_t LOGS_HASHES_NUM_BYTES_PER_BASE_ROLLUP = // TREES RELATED CONSTANTS constexpr size_t VK_TREE_HEIGHT = 3; -constexpr size_t FUNCTION_TREE_HEIGHT = 4; +constexpr size_t FUNCTION_TREE_HEIGHT = 5; constexpr size_t CONTRACT_TREE_HEIGHT = 16; constexpr size_t NOTE_HASH_TREE_HEIGHT = 32; constexpr size_t PUBLIC_DATA_TREE_HEIGHT = 254; diff --git a/l1-contracts/src/core/libraries/ConstantsGen.sol b/l1-contracts/src/core/libraries/ConstantsGen.sol index d63790f5e03..436e18e84b2 100644 --- a/l1-contracts/src/core/libraries/ConstantsGen.sol +++ b/l1-contracts/src/core/libraries/ConstantsGen.sol @@ -44,7 +44,7 @@ library Constants { uint256 internal constant MAX_PUBLIC_DATA_UPDATE_REQUESTS_PER_BASE_ROLLUP = 32; uint256 internal constant MAX_PUBLIC_DATA_READS_PER_BASE_ROLLUP = 32; uint256 internal constant VK_TREE_HEIGHT = 3; - uint256 internal constant FUNCTION_TREE_HEIGHT = 4; + uint256 internal constant FUNCTION_TREE_HEIGHT = 5; uint256 internal constant CONTRACT_TREE_HEIGHT = 16; uint256 internal constant NOTE_HASH_TREE_HEIGHT = 32; uint256 internal constant PUBLIC_DATA_TREE_HEIGHT = 254; diff --git a/yarn-project/aztec-nr/aztec/src/constants_gen.nr b/yarn-project/aztec-nr/aztec/src/constants_gen.nr index 6ac5589e0f8..d1d77e5b81c 100644 --- a/yarn-project/aztec-nr/aztec/src/constants_gen.nr +++ b/yarn-project/aztec-nr/aztec/src/constants_gen.nr @@ -59,7 +59,7 @@ global MAX_PUBLIC_DATA_READS_PER_BASE_ROLLUP: Field = 32; // TREES RELATED CONSTANTS global VK_TREE_HEIGHT: Field = 3; -global FUNCTION_TREE_HEIGHT: Field = 4; +global FUNCTION_TREE_HEIGHT: Field = 5; global CONTRACT_TREE_HEIGHT: Field = 16; global NOTE_HASH_TREE_HEIGHT: Field = 32; global PUBLIC_DATA_TREE_HEIGHT: Field = 254; diff --git a/yarn-project/circuits.js/src/constants.gen.ts b/yarn-project/circuits.js/src/constants.gen.ts index e5fc7359815..89b201b5e5c 100644 --- a/yarn-project/circuits.js/src/constants.gen.ts +++ b/yarn-project/circuits.js/src/constants.gen.ts @@ -30,7 +30,7 @@ export const MAX_NEW_NULLIFIERS_PER_BASE_ROLLUP = 128; export const MAX_PUBLIC_DATA_UPDATE_REQUESTS_PER_BASE_ROLLUP = 32; export const MAX_PUBLIC_DATA_READS_PER_BASE_ROLLUP = 32; export const VK_TREE_HEIGHT = 3; -export const FUNCTION_TREE_HEIGHT = 4; +export const FUNCTION_TREE_HEIGHT = 5; export const CONTRACT_TREE_HEIGHT = 16; export const NOTE_HASH_TREE_HEIGHT = 32; export const PUBLIC_DATA_TREE_HEIGHT = 254; From 0ee5144a895ea444c43d673def2f66c5e0b72080 Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 19:29:41 -0300 Subject: [PATCH 02/13] Add deserialization from buffer for PrivateKernelInputsInner --- .../src/structs/call_stack_item.ts | 16 +++++++++ .../src/structs/kernel/private_kernel.test.ts | 11 +++++++ .../src/structs/kernel/private_kernel.ts | 33 ++++++++++++++++++- .../src/structs/membership_witness.ts | 16 +++++++++ .../structs/private_circuit_public_inputs.ts | 33 ++++++++++++++++++- 5 files changed, 107 insertions(+), 2 deletions(-) create mode 100644 yarn-project/circuits.js/src/structs/kernel/private_kernel.test.ts diff --git a/yarn-project/circuits.js/src/structs/call_stack_item.ts b/yarn-project/circuits.js/src/structs/call_stack_item.ts index 9e1a67857a2..ae9ec202b44 100644 --- a/yarn-project/circuits.js/src/structs/call_stack_item.ts +++ b/yarn-project/circuits.js/src/structs/call_stack_item.ts @@ -1,4 +1,5 @@ import { AztecAddress } from '@aztec/foundation/aztec-address'; +import { BufferReader } from '@aztec/foundation/serialize'; import { computePrivateCallStackItemHash, computePublicCallStackItemHash } from '../abis/abis.js'; import { serializeToBuffer } from '../utils/serialize.js'; @@ -39,6 +40,21 @@ export class PrivateCallStackItem { return serializeToBuffer(this.contractAddress, this.functionData, this.publicInputs, this.isExecutionRequest); } + /** + * Deserializes from a buffer or reader. + * @param buffer - Buffer or reader to read from. + * @returns The deserialized instance. + */ + static fromBuffer(buffer: Buffer | BufferReader): PrivateCallStackItem { + const reader = BufferReader.asReader(buffer); + return new PrivateCallStackItem( + reader.readObject(AztecAddress), + reader.readObject(FunctionData), + reader.readObject(PrivateCircuitPublicInputs), + reader.readBoolean(), + ); + } + /** * Returns a new instance of PrivateCallStackItem with zero contract address, function data and public inputs. * @returns A new instance of PrivateCallStackItem with zero contract address, function data and public inputs. diff --git a/yarn-project/circuits.js/src/structs/kernel/private_kernel.test.ts b/yarn-project/circuits.js/src/structs/kernel/private_kernel.test.ts new file mode 100644 index 00000000000..0adfba51b46 --- /dev/null +++ b/yarn-project/circuits.js/src/structs/kernel/private_kernel.test.ts @@ -0,0 +1,11 @@ +import { makePrivateKernelInputsInner } from '../../tests/factories.js'; +import { PrivateKernelInputsInner } from './private_kernel.js'; + +describe('PrivateKernel', function () { + it(`serializes PrivateKernelInputsInner to buffer and deserializes it back`, () => { + const expected = makePrivateKernelInputsInner(); + const buffer = expected.toBuffer(); + const res = PrivateKernelInputsInner.fromBuffer(buffer); + expect(res).toEqual(expected); + }); +}); diff --git a/yarn-project/circuits.js/src/structs/kernel/private_kernel.ts b/yarn-project/circuits.js/src/structs/kernel/private_kernel.ts index efbef8864c7..fb1740afa67 100644 --- a/yarn-project/circuits.js/src/structs/kernel/private_kernel.ts +++ b/yarn-project/circuits.js/src/structs/kernel/private_kernel.ts @@ -1,5 +1,5 @@ import { Fr } from '@aztec/foundation/fields'; -import { Tuple } from '@aztec/foundation/serialize'; +import { BufferReader, Tuple } from '@aztec/foundation/serialize'; import { CONTRACT_TREE_HEIGHT, @@ -100,6 +100,27 @@ export class PrivateCallData { toBuffer(): Buffer { return serializeToBuffer(...PrivateCallData.getFields(this)); } + + /** + * Deserializes from a buffer or reader. + * @param buffer - Buffer or reader to read from. + * @returns The deserialized instance. + */ + static fromBuffer(buffer: Buffer | BufferReader): PrivateCallData { + const reader = BufferReader.asReader(buffer); + return new PrivateCallData( + reader.readObject(PrivateCallStackItem), + reader.readArray(MAX_PRIVATE_CALL_STACK_LENGTH_PER_CALL, CallRequest), + reader.readArray(MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL, CallRequest), + reader.readObject(Proof), + reader.readObject(VerificationKey), + reader.readObject(MembershipWitness.deserializer(FUNCTION_TREE_HEIGHT)), + reader.readObject(MembershipWitness.deserializer(CONTRACT_TREE_HEIGHT)), + reader.readArray(MAX_READ_REQUESTS_PER_CALL, ReadRequestMembershipWitness), + reader.readObject(Fr), + reader.readObject(Fr), + ); + } } /** @@ -148,6 +169,16 @@ export class PrivateKernelInputsInner { toBuffer() { return serializeToBuffer(this.previousKernel, this.privateCall); } + + /** + * Deserializes from a buffer or reader. + * @param buffer - Buffer or reader to read from. + * @returns The deserialized instance. + */ + static fromBuffer(buffer: Buffer | BufferReader): PrivateKernelInputsInner { + const reader = BufferReader.asReader(buffer); + return new PrivateKernelInputsInner(reader.readObject(PreviousKernelData), reader.readObject(PrivateCallData)); + } } /** diff --git a/yarn-project/circuits.js/src/structs/membership_witness.ts b/yarn-project/circuits.js/src/structs/membership_witness.ts index 083f3d8de73..1115daa76ed 100644 --- a/yarn-project/circuits.js/src/structs/membership_witness.ts +++ b/yarn-project/circuits.js/src/structs/membership_witness.ts @@ -87,6 +87,22 @@ export class MembershipWitness { return this.fromBufferArray(leafIndex, siblingPath); } + /** + * Creates a deserializer object for a MembershipWitness with a given size. + * @param size - Expected size of the witness. + * @returns A deserializer object. + */ + static deserializer(size: N): { fromBuffer(buffer: Buffer | BufferReader): MembershipWitness } { + return { + fromBuffer: (buffer: Buffer | BufferReader) => { + const reader = BufferReader.asReader(buffer); + const leafIndex = toBigIntBE(reader.readBytes(32)); + const siblingPath = reader.readArray(size, Fr); + return new MembershipWitness(size, leafIndex, siblingPath); + }, + }; + } + // import { SiblingPath } from '@aztec/merkle-tree'; // static fromSiblingPath(leafIndex: bigint, siblingPath: SiblingPath): MembershipWitness { // return new MembershipWitness(siblingPath.pathSize, leafIndex, siblingPath.toFieldArray() as Tuple); diff --git a/yarn-project/circuits.js/src/structs/private_circuit_public_inputs.ts b/yarn-project/circuits.js/src/structs/private_circuit_public_inputs.ts index 1b3fe3222fc..b47fd105109 100644 --- a/yarn-project/circuits.js/src/structs/private_circuit_public_inputs.ts +++ b/yarn-project/circuits.js/src/structs/private_circuit_public_inputs.ts @@ -1,6 +1,6 @@ import { isArrayEmpty } from '@aztec/foundation/collection'; import { Fr } from '@aztec/foundation/fields'; -import { Tuple } from '@aztec/foundation/serialize'; +import { BufferReader, Tuple } from '@aztec/foundation/serialize'; import { MAX_NEW_COMMITMENTS_PER_CALL, @@ -106,6 +106,7 @@ export class PrivateCircuitPublicInputs { */ public version: Fr, ) {} + /** * Create PrivateCircuitPublicInputs from a fields dictionary. * @param fields - The dictionary. @@ -115,6 +116,36 @@ export class PrivateCircuitPublicInputs { return new PrivateCircuitPublicInputs(...PrivateCircuitPublicInputs.getFields(fields)); } + /** + * Deserializes from a buffer or reader. + * @param buffer - Buffer or reader to read from. + * @returns The deserialized instance. + */ + static fromBuffer(buffer: Buffer | BufferReader): PrivateCircuitPublicInputs { + const reader = BufferReader.asReader(buffer); + return new PrivateCircuitPublicInputs( + reader.readObject(CallContext), + reader.readObject(Fr), + reader.readArray(RETURN_VALUES_LENGTH, Fr), + reader.readArray(MAX_READ_REQUESTS_PER_CALL, Fr), + reader.readArray(MAX_PENDING_READ_REQUESTS_PER_CALL, Fr), + reader.readArray(MAX_NEW_COMMITMENTS_PER_CALL, Fr), + reader.readArray(MAX_NEW_NULLIFIERS_PER_CALL, Fr), + reader.readArray(MAX_NEW_NULLIFIERS_PER_CALL, Fr), + reader.readArray(MAX_PRIVATE_CALL_STACK_LENGTH_PER_CALL, Fr), + reader.readArray(MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL, Fr), + reader.readArray(MAX_NEW_L2_TO_L1_MSGS_PER_CALL, Fr), + reader.readArray(NUM_FIELDS_PER_SHA256, Fr), + reader.readArray(NUM_FIELDS_PER_SHA256, Fr), + reader.readObject(Fr), + reader.readObject(Fr), + reader.readObject(BlockHeader), + reader.readObject(ContractDeploymentData), + reader.readObject(Fr), + reader.readObject(Fr), + ); + } + /** * Create an empty PrivateCircuitPublicInputs. * @returns An empty PrivateCircuitPublicInputs object. From 45bd67c65d1a176d191cedb3cdfdd7932a6c040b Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 19:32:25 -0300 Subject: [PATCH 03/13] Add util to foundation for collecting generated data in e2e tests --- yarn-project/foundation/package.json | 3 +- yarn-project/foundation/src/index.ts | 1 + yarn-project/foundation/src/testing/index.ts | 1 + .../foundation/src/testing/test_data.ts | 36 +++++++++++++++++++ 4 files changed, 40 insertions(+), 1 deletion(-) create mode 100644 yarn-project/foundation/src/testing/index.ts create mode 100644 yarn-project/foundation/src/testing/test_data.ts diff --git a/yarn-project/foundation/package.json b/yarn-project/foundation/package.json index 98a10914965..372c031ef39 100644 --- a/yarn-project/foundation/package.json +++ b/yarn-project/foundation/package.json @@ -34,7 +34,8 @@ "./types": "./dest/types/index.js", "./url": "./dest/url/index.js", "./committable": "./dest/committable/index.js", - "./noir": "./dest/noir/index.js" + "./noir": "./dest/noir/index.js", + "./testing": "./dest/testing/index.js" }, "scripts": { "build": "yarn clean && tsc -b", diff --git a/yarn-project/foundation/src/index.ts b/yarn-project/foundation/src/index.ts index b34a0bf474e..c75ef10e563 100644 --- a/yarn-project/foundation/src/index.ts +++ b/yarn-project/foundation/src/index.ts @@ -25,3 +25,4 @@ export * as types from './types/index.js'; export * as url from './url/index.js'; export * as wasm from './wasm/index.js'; export * as worker from './worker/index.js'; +export * as testing from './testing/index.js'; diff --git a/yarn-project/foundation/src/testing/index.ts b/yarn-project/foundation/src/testing/index.ts new file mode 100644 index 00000000000..40be26eb4ef --- /dev/null +++ b/yarn-project/foundation/src/testing/index.ts @@ -0,0 +1 @@ +export * from './test_data.js'; diff --git a/yarn-project/foundation/src/testing/test_data.ts b/yarn-project/foundation/src/testing/test_data.ts new file mode 100644 index 00000000000..f6ceaaa371f --- /dev/null +++ b/yarn-project/foundation/src/testing/test_data.ts @@ -0,0 +1,36 @@ +const testData: { [key: string]: { toBuffer(): Buffer }[] } = {}; + +/** Returns whether test data generation is enabled */ +export function isGenerateTestDataEnabled() { + return process.env.AZTEC_GENERATE_TEST_DATA === '1' || typeof expect !== 'undefined'; +} + +/** Pushes test data with the given name, only if test data generation is enabled. */ +export function pushTestData(itemName: string, data: { toBuffer(): Buffer }) { + if (!isGenerateTestDataEnabled()) { + return; + } + + if (typeof expect === 'undefined') { + return; + } + + const testName = expect.getState().currentTestName; + const fullItemName = `${testName} ${itemName}`; + + if (!testData[fullItemName]) { + testData[fullItemName] = []; + } + testData[fullItemName].push(data); +} + +/** Returns all instances of pushed test data with the given name, or empty if test data generation is not enabled. */ +export function getTestData(itemName: string): { toBuffer(): Buffer }[] { + if (!isGenerateTestDataEnabled()) { + return []; + } + + const testName = expect.getState().currentTestName; + const fullItemName = `${testName} ${itemName}`; + return testData[fullItemName]; +} From 197dc69262dc124526a0ac0ea13b5480153f29ae Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 19:33:32 -0300 Subject: [PATCH 04/13] Unhardcode data from noir-circuit test and load from generated data in e2e test --- .../src/e2e_nested_contract.test.ts | 12 + .../src/__snapshots__/index.test.ts.snap | 366 +++++++++--------- .../nested-call-private-kernel-inner.hex | 1 + .../noir-protocol-circuits/src/index.test.ts | 151 +------- .../pxe/src/kernel_prover/kernel_prover.ts | 10 +- 5 files changed, 213 insertions(+), 327 deletions(-) create mode 100644 yarn-project/noir-protocol-circuits/src/fixtures/nested-call-private-kernel-inner.hex diff --git a/yarn-project/end-to-end/src/e2e_nested_contract.test.ts b/yarn-project/end-to-end/src/e2e_nested_contract.test.ts index f34c691addf..e390a85a4f7 100644 --- a/yarn-project/end-to-end/src/e2e_nested_contract.test.ts +++ b/yarn-project/end-to-end/src/e2e_nested_contract.test.ts @@ -1,6 +1,9 @@ import { AztecAddress, BatchCall, DebugLogger, Fr, PXE, Wallet, toBigIntBE } from '@aztec/aztec.js'; +import { getTestData, isGenerateTestDataEnabled } from '@aztec/foundation/testing'; import { ChildContract, ImportTestContract, ParentContract, TestContract } from '@aztec/noir-contracts/types'; +import { writeFileSync } from 'fs'; + import { setup } from './fixtures/utils.js'; describe('e2e_nested_contract', () => { @@ -31,6 +34,15 @@ describe('e2e_nested_contract', () => { .entryPoint(childContract.address, childContract.methods.value.selector.toField()) .send() .wait(); + + if (isGenerateTestDataEnabled()) { + const privateKernelInputs = getTestData('private-kernel-inputs-inner'); + const nestedCallPrivateKernelInput = privateKernelInputs[privateKernelInputs.length - 1]; + writeFileSync( + '../noir-protocol-circuits/src/fixtures/nested-call-private-kernel-inner.hex', + nestedCallPrivateKernelInput.toBuffer().toString('hex'), + ); + } }, 100_000); it('fails simulation if calling a function not allowed to be called externally', async () => { diff --git a/yarn-project/noir-protocol-circuits/src/__snapshots__/index.test.ts.snap b/yarn-project/noir-protocol-circuits/src/__snapshots__/index.test.ts.snap index af2dbd89ecb..4cf926dc96a 100644 --- a/yarn-project/noir-protocol-circuits/src/__snapshots__/index.test.ts.snap +++ b/yarn-project/noir-protocol-circuits/src/__snapshots__/index.test.ts.snap @@ -25721,121 +25721,121 @@ KernelCircuitPublicInputs { "constants": CombinedConstantData { "blockHeader": BlockHeader { "blocksTreeRoot": Fr { - "asBigInt": 5141115076863619919216387293080007096006645021873634395499188999297490933851n, + "asBigInt": 4141256197271035428567950264296887925803599654022881395228888440470800002298n, "asBuffer": { "data": [ - 11, - 93, - 196, - 156, - 165, - 27, - 8, - 118, - 48, - 34, - 10, - 13, - 152, - 139, - 232, + 9, + 39, + 222, + 49, + 149, + 188, + 22, + 194, + 228, 185, - 74, - 90, - 30, - 31, - 89, - 156, - 148, - 205, - 159, - 107, - 213, 87, - 0, - 138, - 216, - 91, + 94, + 14, + 102, + 227, + 106, + 225, + 154, + 204, + 195, + 105, + 44, + 167, + 185, + 41, + 119, + 195, + 190, + 193, + 13, + 108, + 250, ], "type": "Buffer", }, }, "contractTreeRoot": Fr { - "asBigInt": 21460711749780266085286753025152205037129726990627677844053346835116758120820n, + "asBigInt": 5581248852067966506476110357785496963917224136518690137510493228293502103930n, "asBuffer": { "data": [ - 47, - 114, - 85, - 24, - 52, + 12, + 86, + 223, + 249, + 180, + 193, + 103, + 122, + 71, + 221, + 147, + 211, + 135, + 162, + 135, + 26, 67, - 7, - 30, - 148, - 233, - 6, - 81, - 89, - 60, - 70, - 52, - 41, - 120, - 230, - 137, - 225, - 244, - 243, - 228, - 2, - 97, - 111, - 165, - 150, - 51, - 185, - 116, + 102, + 193, + 61, + 168, + 180, + 252, + 159, + 133, + 200, + 174, + 12, + 10, + 53, + 113, + 122, ], "type": "Buffer", }, }, "globalVariablesHash": Fr { - "asBigInt": 8804617544473098471281054303034464911880382710731022213211231932632369293839n, + "asBigInt": 10982507924920738674805945892274185625046296695654177390082807748667229078837n, "asBuffer": { "data": [ + 24, + 71, + 225, 19, - 119, - 60, - 167, - 129, - 12, - 178, - 53, - 98, - 66, - 15, - 81, - 251, - 159, + 115, + 109, + 194, + 36, + 28, + 183, + 24, + 36, 233, - 197, + 201, + 246, 253, - 245, - 150, - 39, + 41, + 76, + 59, + 132, 31, - 201, - 171, - 120, - 215, - 104, - 188, - 165, - 20, + 252, + 116, + 77, + 98, 189, - 106, - 15, + 49, + 231, + 160, + 196, + 5, + 53, ], "type": "Buffer", }, @@ -25881,81 +25881,81 @@ KernelCircuitPublicInputs { }, }, "noteHashTreeRoot": Fr { - "asBigInt": 6222745529025398016447443066268738212146684011532595570360754935429642618932n, + "asBigInt": 19936675125770429878298489304626860431485064106154993611029467200819125156683n, "asBuffer": { "data": [ - 13, - 193, - 242, - 251, - 231, - 124, - 12, - 114, - 211, - 41, - 204, - 99, - 242, - 189, - 136, - 205, - 118, - 163, - 12, - 88, - 2, - 248, + 44, 19, - 136, - 20, - 135, - 76, - 195, - 40, - 20, - 136, - 52, + 194, + 28, + 1, + 245, + 22, + 101, + 227, + 237, + 34, + 250, + 157, + 184, + 204, + 132, + 63, + 31, + 60, + 153, + 200, + 185, + 110, + 87, + 26, + 255, + 192, + 247, + 77, + 237, + 251, + 75, ], "type": "Buffer", }, }, "nullifierTreeRoot": Fr { - "asBigInt": 11028380920778709529422849579366115012465279492588387885897402657110319591536n, + "asBigInt": 4586703266286347436402481541702375293800259937188486151561348105796608164964n, "asBuffer": { "data": [ - 24, - 97, - 215, - 167, - 111, - 76, - 143, - 125, - 185, - 95, - 168, + 10, + 35, + 251, + 103, 170, + 184, + 66, + 16, + 60, + 0, + 100, + 234, + 184, + 234, + 231, + 175, + 44, + 208, + 126, + 190, + 35, + 140, + 53, + 186, 27, - 203, - 221, - 92, - 191, - 87, - 110, - 254, + 189, + 135, + 165, 23, - 69, - 95, - 238, - 105, - 143, - 98, - 82, - 146, - 102, - 112, - 112, + 153, + 132, + 100, ], "type": "Buffer", }, @@ -29425,41 +29425,41 @@ KernelCircuitPublicInputs { ], "newNullifiers": [ Fr { - "asBigInt": 1235925639612797312069034095263162367684241589155703435493934869634517203353n, + "asBigInt": 17066526537155008625801148970628416876452664863580543040821415016087256242169n, "asBuffer": { "data": [ - 2, + 37, 187, - 130, - 85, - 215, - 170, - 50, - 29, - 131, - 181, - 9, - 19, - 32, + 79, + 204, + 6, 92, - 128, - 192, - 78, + 222, + 117, + 146, + 104, + 60, + 208, + 138, + 215, + 82, + 15, + 212, + 189, + 44, + 138, + 125, + 108, + 69, + 248, + 102, + 158, + 186, 229, - 19, - 96, - 219, - 200, - 170, - 61, - 83, - 147, - 152, - 58, - 57, - 38, - 121, - 153, + 52, + 175, + 23, + 249, ], "type": "Buffer", }, diff --git a/yarn-project/noir-protocol-circuits/src/fixtures/nested-call-private-kernel-inner.hex b/yarn-project/noir-protocol-circuits/src/fixtures/nested-call-private-kernel-inner.hex new file mode 100644 index 00000000000..aa94d01cee9 --- /dev/null +++ b/yarn-project/noir-protocol-circuits/src/fixtures/nested-call-private-kernel-inner.hex @@ -0,0 +1 @@ +0000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000002000000000000001000000bd300000bd400000bd500000bd600000bd700000bd800000bd900000bda00000bdb00000bdc00000bdd00000bde00000bdf00000be000000be100000be2000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000025bb4fcc065cde7592683cd08ad7520fd4bd2c8a7d6c45f8669ebae534af17f900000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f4240000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000148ba6131c054214fc5f0a80f3935c19e7b2d33c454768be65aaf3690b785d32176410961fff9aa7f2199074259d844d8d33430da28b366483ca730ac5fa4657000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000d3735899d9fa7162447ca631f0ba2cd500000000000000000000000000000000eb57d0965a756d78291da33072610eb200000000000000000000000000000000d3735899d9fa7162447ca631f0ba2cd500000000000000000000000000000000eb57d0965a756d78291da33072610eb2000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c13c21c01f51665e3ed22fa9db8cc843f1f3c99c8b96e571affc0f74dedfb4b0a23fb67aab842103c0064eab8eae7af2cd07ebe238c35ba1bbd87a5179984640c56dff9b4c1677a47dd93d387a2871a4366c13da8b4fc9f85c8ae0c0a35717a1864fcdaa80ff2719154fa7c8a9050662972707168d69eac9db6fd3110829f800927de3195bc16c2e4b9575e0e66e36ae19accc3692ca7b92977c3bec10d6cfa00000000000000000000000000000000000000000000000000000000000000000ccaafdc9c353743970d4e305ae73641ce694f07db67886d2769c9ed88e969d81847e113736dc2241cb71824e9c9f6fd294c3b841ffc744d62bd31e7a0c405350000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007a69000000000000000000000000000000000000000000000000000000000000000101000000000000000200000800000000740000000f00000003515f3109623eb3c25aa5b16a1a79fd558bac7a7ce62c4560a8c537c77ce80dd339128d1d37b6582ee9e6df9567efb64313471dfa18f520f9ce53161b50dbf7731bc5f900000003515f322bc4cce83a486a92c92fd59bd84e0f92595baa639fc2ed86b00ffa0dfded2a092a669a3bdb7a273a015eda494457cc7ed5236f26cee330c290d45a33b9daa94800000003515f332729426c008c085a81bd34d8ef12dd31e80130339ef99d50013a89e4558eee6d0fa4ffe2ee7b7b62eb92608b2251ac31396a718f9b34978888789042b790a30100000003515f342be6b6824a913eb7a57b03cb1ee7bfb4de02f2f65fe8a4e97baa7766ddb353a82a8a25c49dc63778cd9fe96173f12a2bc77f3682f4c4448f98f1df82c75234a100000003515f351f85760d6ab567465aadc2f180af9eae3800e6958fec96aef53fd8a7b195d7c000c6267a0dd5cfc22b3fe804f53e266069c0e36f51885baec1e7e67650c62e170000000c515f41524954484d455449430d9d0f8ece2aa12012fa21e6e5c859e97bd5704e5c122064a66051294bc5e04213f61f54a0ebdf6fee4d4a6ecf693478191de0c2899bcd8e86a636c8d3eff43400000003515f43224a99d02c86336737c8dd5b746c40d2be6aead8393889a76a18d664029096e90f7fe81adcc92a74350eada9622ac453f49ebac24a066a1f83b394df54dfa0130000000c515f46495845445f42415345060e8a013ed289c2f9fd7473b04f6594b138ddb4b4cf6b901622a14088f04b8d2c83ff74fce56e3d5573b99c7b26d85d5046ce0c6559506acb7a675e7713eb3a00000007515f4c4f4749430721a91cb8da4b917e054f72147e1760cfe0ef3d45090ac0f4961d84ec1996961a25e787b26bd8b50b1a99450f77a424a83513c2b33af268cd253b0587ff50c700000003515f4d05dbd8623b8652511e1eb38d38887a69eceb082f807514f09e127237c5213b401b9325b48c6c225968002318095f89d0ef9cf629b2b7f0172e03bc39aacf6ed800000007515f52414e474504b57a3805e41df328f5ca9aefa40fad5917391543b7b65c6476e60b8f72e9ad07c92f3b3e11c8feae96dedc4b14a6226ef3201244f37cfc1ee5b96781f48d2b000000075349474d415f3125001d1954a18571eaa007144c5a567bb0d2be4def08a8be918b8c05e3b27d312c59ed41e09e144eab5de77ca89a2fd783be702a47c951d3112e3de02ce6e47c000000075349474d415f3223994e6a23618e60fa01c449a7ab88378709197e186d48d604bfb6931ffb15ad11c5ec7a0700570f80088fd5198ab5d5c227f2ad2a455a6edeec024156bb7beb000000075349474d415f3300cda5845f23468a13275d18bddae27c6bb189cf9aa95b6a03a0cb6688c7e8d829639b45cf8607c525cc400b55ebf90205f2f378626dc3406cc59b2d1b474fba000000075349474d415f342d299e7928496ea2d37f10b43afd6a80c90a33b483090d18069ffa275eedb2fc2f82121e8de43dc036d99b478b6227ceef34248939987a19011f065d8b5cef5c0000000010000000000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f0000000027f7bade13501a6b49961658bf38e9b0359fa8957a3d02e162498cb12fc6eeca0f952401790a7b2caa2a245f0663b57173876d0737255a4329665fe639069a6a2e3578ab81ada96187e62987873863ee79909f55e49ebddb42e2684668b90b7b0cab1a95b4e7352568da9513c6d61f1b5b4ad9c8d270e4aac2b7685ab9fa27460906bca1000100176410961fff9aa7f2199074259d844d8d33430da28b366483ca730ac5fa46570cab1a95b4e7352568da9513c6d61f1b5b4ad9c8d270e4aac2b7685ab9fa274600000000000000000000000000000000000000000000000000000000000000000906bca10000001124bf00bac5cd7fc8570fe0e40c34b8d093801a155d53e0b478d960b3a424810000000000000000000000000000000000000000000000000000000000007a6a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e3b0c44298fc1c149afbf4c8996fb9240000000000000000000000000000000027ae41e4649b934ca495991b7852b85500000000000000000000000000000000e3b0c44298fc1c149afbf4c8996fb9240000000000000000000000000000000027ae41e4649b934ca495991b7852b855000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000042c13c21c01f51665e3ed22fa9db8cc843f1f3c99c8b96e571affc0f74dedfb4b0a23fb67aab842103c0064eab8eae7af2cd07ebe238c35ba1bbd87a5179984640c56dff9b4c1677a47dd93d387a2871a4366c13da8b4fc9f85c8ae0c0a35717a1864fcdaa80ff2719154fa7c8a9050662972707168d69eac9db6fd3110829f800927de3195bc16c2e4b9575e0e66e36ae19accc3692ca7b92977c3bec10d6cfa00000000000000000000000000000000000000000000000000000000000000000ccaafdc9c353743970d4e305ae73641ce694f07db67886d2769c9ed88e969d81847e113736dc2241cb71824e9c9f6fd294c3b841ffc744d62bd31e7a0c405350000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007a6900000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000800000000740000000f00000003515f3109623eb3c25aa5b16a1a79fd558bac7a7ce62c4560a8c537c77ce80dd339128d1d37b6582ee9e6df9567efb64313471dfa18f520f9ce53161b50dbf7731bc5f900000003515f322bc4cce83a486a92c92fd59bd84e0f92595baa639fc2ed86b00ffa0dfded2a092a669a3bdb7a273a015eda494457cc7ed5236f26cee330c290d45a33b9daa94800000003515f332729426c008c085a81bd34d8ef12dd31e80130339ef99d50013a89e4558eee6d0fa4ffe2ee7b7b62eb92608b2251ac31396a718f9b34978888789042b790a30100000003515f342be6b6824a913eb7a57b03cb1ee7bfb4de02f2f65fe8a4e97baa7766ddb353a82a8a25c49dc63778cd9fe96173f12a2bc77f3682f4c4448f98f1df82c75234a100000003515f351f85760d6ab567465aadc2f180af9eae3800e6958fec96aef53fd8a7b195d7c000c6267a0dd5cfc22b3fe804f53e266069c0e36f51885baec1e7e67650c62e170000000c515f41524954484d455449430d9d0f8ece2aa12012fa21e6e5c859e97bd5704e5c122064a66051294bc5e04213f61f54a0ebdf6fee4d4a6ecf693478191de0c2899bcd8e86a636c8d3eff43400000003515f43224a99d02c86336737c8dd5b746c40d2be6aead8393889a76a18d664029096e90f7fe81adcc92a74350eada9622ac453f49ebac24a066a1f83b394df54dfa0130000000c515f46495845445f42415345060e8a013ed289c2f9fd7473b04f6594b138ddb4b4cf6b901622a14088f04b8d2c83ff74fce56e3d5573b99c7b26d85d5046ce0c6559506acb7a675e7713eb3a00000007515f4c4f4749430721a91cb8da4b917e054f72147e1760cfe0ef3d45090ac0f4961d84ec1996961a25e787b26bd8b50b1a99450f77a424a83513c2b33af268cd253b0587ff50c700000003515f4d05dbd8623b8652511e1eb38d38887a69eceb082f807514f09e127237c5213b401b9325b48c6c225968002318095f89d0ef9cf629b2b7f0172e03bc39aacf6ed800000007515f52414e474504b57a3805e41df328f5ca9aefa40fad5917391543b7b65c6476e60b8f72e9ad07c92f3b3e11c8feae96dedc4b14a6226ef3201244f37cfc1ee5b96781f48d2b000000075349474d415f3125001d1954a18571eaa007144c5a567bb0d2be4def08a8be918b8c05e3b27d312c59ed41e09e144eab5de77ca89a2fd783be702a47c951d3112e3de02ce6e47c000000075349474d415f3223994e6a23618e60fa01c449a7ab88378709197e186d48d604bfb6931ffb15ad11c5ec7a0700570f80088fd5198ab5d5c227f2ad2a455a6edeec024156bb7beb000000075349474d415f3300cda5845f23468a13275d18bddae27c6bb189cf9aa95b6a03a0cb6688c7e8d829639b45cf8607c525cc400b55ebf90205f2f378626dc3406cc59b2d1b474fba000000075349474d415f342d299e7928496ea2d37f10b43afd6a80c90a33b483090d18069ffa275eedb2fc2f82121e8de43dc036d99b478b6227ceef34248939987a19011f065d8b5cef5c0000000010000000000000000100000002000000030000000400000005000000060000000700000008000000090000000a0000000b0000000c0000000d0000000e0000000f000000000000000000000000000000000000000000000000000000000000000722a1419dd08e208cd862bb66fb009fa540fb7178d01108f79eb78a891064685603f30687851ce0bc4df8e4fa8a5809643e9ae7f752a3ec1e3c120b251036c92e14ae899cd34041169f2476b70040373713d6eb363e74dca7f7f70f36d286b92f044b59fe1a64065611c9ec171fc760af4337fd13bbb833a9b021cfdde27a7f621a9fdb505152f9c2baaffe4a30ee80775b58ebf8c2dde76435835b085c6f70ca0000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000027b1d0839a5b23baf12a8d195b18ac288fcf401afb2f70b8a4b529ede5fa9fed21dbfd1d029bf447152fcf89e355c334610d1632436ba170f738107266a71550207cf0529e39f81dbb6ab5f6a2dce3907f2218c8673874a2bf62f7b3641d7dc006e62084ee7b602fe9abc15632dda3269f56fb0c6e12519a2eb2ec897091919d03c9e2e67178ac638746f068907e6677b4cc7a9592ef234ab6ab518f17efffa015d28cad4c0736decea8997cb324cf0a0e0602f4d74472cd977bce2c8dd9923f268ed1e1c94c3a45a14db4108bc306613a1c23fab68e0466a002dfb0a3f8d2ab0cd8d5695bc2dde99dd531671f76f1482f14ddba8eeca7cb9686d4a62359c257047fbb7eb974155702149e58ea6ad91f4c6e953e693db35e953e250d8ceac9a900c5ae2526e665e2c7c698c11a06098b7159f720606d50e7660deb55758b0b022ced19489ab456b8b6c424594cdbbae59c36dfdd4c4621c4032da2d8a9674be51df5a245ffc1da14b46fe56a605f2a47b1cff1592bab4f66cfe5dfe990af6ab52871d090615d14eadb52228c635c90e0adf31176f0814f6525c23e7d7b318c931a2b85ff013d4b2b25074297c7e44aa61f4836d0862b36db2e6ce2b5542f9ea9177b9a10bbee32f77c719c6f8d071a18476cbeb021e155c642bbf93c716ce94300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 \ No newline at end of file diff --git a/yarn-project/noir-protocol-circuits/src/index.test.ts b/yarn-project/noir-protocol-circuits/src/index.test.ts index 974269bb8f7..ee456f8e4fb 100644 --- a/yarn-project/noir-protocol-circuits/src/index.test.ts +++ b/yarn-project/noir-protocol-circuits/src/index.test.ts @@ -57,6 +57,10 @@ import { import { computeCompleteAddress, computeFunctionLeaf, computeTxHash } from '@aztec/circuits.js/abis'; import { Fr } from '@aztec/foundation/fields'; import { DebugLogger, createDebugLogger } from '@aztec/foundation/log'; +import { fileURLToPath } from '@aztec/foundation/url'; + +import { readFileSync } from 'fs'; +import { dirname, resolve } from 'path'; import { executeInit, executeInner, executeOrdering } from './index.js'; @@ -250,150 +254,17 @@ describe('Private kernel', () => { }); // Taken from e2e_nested_contract => performs nested calls => last inner + // To regenerate fixture data run the following on the yarn-project/e2e folder + // AZTEC_GENERATE_TEST_DATA=1 yarn test e2e_nested_contract -t 'performs nested calls' it('Executes private kernel inner for a nested call', async () => { logger('Initialized Noir instance with private kernel init circuit'); - const argsHash = Fr.fromString('0x1124bf00bac5cd7fc8570fe0e40c34b8d093801a155d53e0b478d960b3a42481'); - - const selector = FunctionSelector.fromString('0x0906bca1'); - const functionData = new FunctionData(selector, false, true, false); - const chainId = Fr.fromString('0x7a69'); - const version = new Fr(1n); - const txContext = new TxContext(false, false, false, ContractDeploymentData.empty(), chainId, version); - - const contractAddress = AztecAddress.fromString( - '0x1cef2ccea866fe30510b6ba5d155dc7725dc0dbc487c079221fb19a988687105', - ); - - const callContext = new CallContext( - AztecAddress.fromString('0x0af61403460f2cef4bde3118e1e0868ea4917bf14039de8eb0e5d9d3c30af1a5'), - contractAddress, - Fr.ZERO, - selector, - false, - false, - false, - ); - - const blockHeader = new BlockHeader( - Fr.fromString('0x0dc1f2fbe77c0c72d329cc63f2bd88cd76a30c5802f8138814874cc328148834'), - Fr.fromString('0x1861d7a76f4c8f7db95fa8aa1bcbdd5cbf576efe17455fee698f625292667070'), - Fr.fromString('0x2f7255183443071e94e90651593c46342978e689e1f4f3e402616fa59633b974'), - Fr.fromString('0x1864fcdaa80ff2719154fa7c8a9050662972707168d69eac9db6fd3110829f80'), - Fr.fromString('0x0b5dc49ca51b087630220a0d988be8b94a5a1e1f599c94cd9f6bd557008ad85b'), - Fr.ZERO, - Fr.fromString('0x0ccaafdc9c353743970d4e305ae73641ce694f07db67886d2769c9ed88e969d8'), - Fr.fromString('0x13773ca7810cb23562420f51fb9fe9c5fdf596271fc9ab78d768bca514bd6a0f'), + const filepath = resolve( + dirname(fileURLToPath(import.meta.url)), + './fixtures/nested-call-private-kernel-inner.hex', ); - - const appReturnValues = makeTuple(RETURN_VALUES_LENGTH, () => Fr.ZERO); - appReturnValues[0] = Fr.fromString('0x7a6a'); - - const appPublicInputs = new PrivateCircuitPublicInputs( - callContext, - argsHash, - appReturnValues, - makeTuple(MAX_READ_REQUESTS_PER_CALL, () => Fr.ZERO), - makeTuple(MAX_PENDING_READ_REQUESTS_PER_CALL, () => Fr.ZERO), - makeTuple(MAX_NEW_COMMITMENTS_PER_CALL, () => Fr.ZERO), - makeTuple(MAX_NEW_NULLIFIERS_PER_CALL, () => Fr.ZERO), - makeTuple(MAX_NEW_NULLIFIERS_PER_CALL, () => Fr.ZERO), - makeTuple(MAX_PRIVATE_CALL_STACK_LENGTH_PER_CALL, () => Fr.ZERO), - makeTuple(MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL, () => Fr.ZERO), - makeTuple(MAX_NEW_L2_TO_L1_MSGS_PER_CALL, () => Fr.ZERO), - [Fr.fromString('0xe3b0c44298fc1c149afbf4c8996fb924'), Fr.fromString('0x27ae41e4649b934ca495991b7852b855')], - [Fr.fromString('0xe3b0c44298fc1c149afbf4c8996fb924'), Fr.fromString('0x27ae41e4649b934ca495991b7852b855')], - Fr.fromString('0x04'), - Fr.fromString('0x04'), - blockHeader, - ContractDeploymentData.empty(), - chainId, - version, - ); - - const callStackItem = new PrivateCallStackItem(contractAddress, functionData, appPublicInputs, false); - - const privateCall = new PrivateCallData( - callStackItem, - makeTuple(MAX_PRIVATE_CALL_STACK_LENGTH_PER_CALL, () => CallRequest.empty()), - makeTuple(MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL, () => CallRequest.empty()), - makeEmptyProof(), - VerificationKey.makeFake(), - new MembershipWitness(FUNCTION_TREE_HEIGHT, 7n, [ - Fr.fromString('0x22a1419dd08e208cd862bb66fb009fa540fb7178d01108f79eb78a8910646856'), - Fr.fromString('0x03f30687851ce0bc4df8e4fa8a5809643e9ae7f752a3ec1e3c120b251036c92e'), - Fr.fromString('0x14ae899cd34041169f2476b70040373713d6eb363e74dca7f7f70f36d286b92f'), - Fr.fromString('0x044b59fe1a64065611c9ec171fc760af4337fd13bbb833a9b021cfdde27a7f62'), - ]), - new MembershipWitness(CONTRACT_TREE_HEIGHT, 8n, [ - Fr.fromString('0x00'), - Fr.fromString('0x27b1d0839a5b23baf12a8d195b18ac288fcf401afb2f70b8a4b529ede5fa9fed'), - Fr.fromString('0x21dbfd1d029bf447152fcf89e355c334610d1632436ba170f738107266a71550'), - Fr.fromString('0x233c769a05f4abccf12ee26e14d7f9eee8f2cb01678c42d802c0e25f05977555'), - Fr.fromString('0x06e62084ee7b602fe9abc15632dda3269f56fb0c6e12519a2eb2ec897091919d'), - Fr.fromString('0x03c9e2e67178ac638746f068907e6677b4cc7a9592ef234ab6ab518f17efffa0'), - Fr.fromString('0x15d28cad4c0736decea8997cb324cf0a0e0602f4d74472cd977bce2c8dd9923f'), - Fr.fromString('0x268ed1e1c94c3a45a14db4108bc306613a1c23fab68e0466a002dfb0a3f8d2ab'), - Fr.fromString('0x0cd8d5695bc2dde99dd531671f76f1482f14ddba8eeca7cb9686d4a62359c257'), - Fr.fromString('0x047fbb7eb974155702149e58ea6ad91f4c6e953e693db35e953e250d8ceac9a9'), - Fr.fromString('0xc5ae2526e665e2c7c698c11a06098b7159f720606d50e7660deb55758b0b02'), - Fr.fromString('0x2ced19489ab456b8b6c424594cdbbae59c36dfdd4c4621c4032da2d8a9674be5'), - Fr.fromString('0x1df5a245ffc1da14b46fe56a605f2a47b1cff1592bab4f66cfe5dfe990af6ab5'), - Fr.fromString('0x2871d090615d14eadb52228c635c90e0adf31176f0814f6525c23e7d7b318c93'), - Fr.fromString('0x1a2b85ff013d4b2b25074297c7e44aa61f4836d0862b36db2e6ce2b5542f9ea9'), - Fr.fromString('0x177b9a10bbee32f77c719c6f8d071a18476cbeb021e155c642bbf93c716ce943'), - ]), - makeTuple(MAX_READ_REQUESTS_PER_CALL, () => ReadRequestMembershipWitness.empty(0n)), - Fr.ZERO, - Fr.ZERO, - ); - - const privateCallStack = makeTuple(MAX_PRIVATE_CALL_STACK_LENGTH_PER_TX, () => CallRequest.empty()); - privateCallStack[0].hash = Fr.fromString('0x036ce317b74895ab56dc5ed6943f14a73c570ae6cde751a588f4522052bb2b20'); - privateCallStack[0].callerContractAddress = callContext.msgSender; - - const newCommitments = makeTuple(MAX_NEW_COMMITMENTS_PER_CALL, () => Fr.ZERO); - newCommitments[0] = Fr.fromString('0x0aced88c953b70873e4a33dde4620dc43a709c15013c46c60d167de8e1c32315'); - - const newNullifiers = makeTuple(MAX_NEW_NULLIFIERS_PER_TX, () => Fr.ZERO); - newNullifiers[0] = Fr.fromString('0x02bb8255d7aa321d83b50913205c80c04ee51360dbc8aa3d5393983a39267999'); - - const nullifiedCommitments = makeTuple(MAX_NEW_NULLIFIERS_PER_TX, () => Fr.ZERO); - nullifiedCommitments[0] = Fr.fromString('0x0f4240'); - - const combinedAccumulatedData = new CombinedAccumulatedData( - AggregationObject.makeFake(), - makeTuple(MAX_READ_REQUESTS_PER_TX, () => new Fr(0n)), - makeTuple(MAX_PENDING_READ_REQUESTS_PER_TX, () => new Fr(0n)), - makeTuple(MAX_NEW_COMMITMENTS_PER_TX, () => new Fr(0n)), - newNullifiers, - nullifiedCommitments, - privateCallStack, - makeTuple(MAX_PUBLIC_CALL_STACK_LENGTH_PER_TX, () => CallRequest.empty()), - makeTuple(MAX_NEW_L2_TO_L1_MSGS_PER_CALL, () => new Fr(0n)), - [Fr.fromString('0xd3735899d9fa7162447ca631f0ba2cd5'), Fr.fromString('0xeb57d0965a756d78291da33072610eb2')], - [Fr.fromString('0xd3735899d9fa7162447ca631f0ba2cd5'), Fr.fromString('0xeb57d0965a756d78291da33072610eb2')], - new Fr(8), - new Fr(8), - [NewContractData.empty()], - makeTuple(MAX_OPTIONALLY_REVEALED_DATA_LENGTH_PER_TX, () => OptionallyRevealedData.empty()), - makeTuple(MAX_PUBLIC_DATA_UPDATE_REQUESTS_PER_TX, () => PublicDataUpdateRequest.empty()), - makeTuple(MAX_PUBLIC_DATA_READS_PER_TX, () => PublicDataRead.empty()), - ); - - const constants = new CombinedConstantData(blockHeader, txContext); - - const kernelPublicInputs = new KernelCircuitPublicInputs(combinedAccumulatedData, constants, true); - - const previousKernelData = new PreviousKernelData( - kernelPublicInputs, - makeEmptyProof(), - VerificationKey.makeFake(), - 0, - makeTuple(VK_TREE_HEIGHT, () => Fr.ZERO), - ); - - const kernelInputs = new PrivateKernelInputsInner(previousKernelData, privateCall); + const serialized = Buffer.from(readFileSync(filepath).toString(), 'hex'); + const kernelInputs = PrivateKernelInputsInner.fromBuffer(serialized); const kernelOutputs = await executeInner(kernelInputs); diff --git a/yarn-project/pxe/src/kernel_prover/kernel_prover.ts b/yarn-project/pxe/src/kernel_prover/kernel_prover.ts index 2b28b61ba16..d69b2babe5c 100644 --- a/yarn-project/pxe/src/kernel_prover/kernel_prover.ts +++ b/yarn-project/pxe/src/kernel_prover/kernel_prover.ts @@ -27,6 +27,7 @@ import { } from '@aztec/circuits.js'; import { padArrayEnd } from '@aztec/foundation/collection'; import { Tuple, assertLength } from '@aztec/foundation/serialize'; +import { pushTestData } from '@aztec/foundation/testing'; import { KernelProofCreator, ProofCreator, ProofOutput, ProofOutputFinal } from './proof_creator.js'; import { ProvingDataOracle } from './proving_data_oracle.js'; @@ -134,7 +135,8 @@ export class KernelProver { ); if (firstIteration) { - output = await this.proofCreator.createProofInit(new PrivateKernelInputsInit(txRequest, privateCallData)); + const proofInput = new PrivateKernelInputsInit(txRequest, privateCallData); + output = await this.proofCreator.createProofInit(proofInput); } else { const previousVkMembershipWitness = await this.oracle.getVkMembershipWitness(previousVerificationKey); const previousKernelData = new PreviousKernelData( @@ -144,9 +146,9 @@ export class KernelProver { Number(previousVkMembershipWitness.leafIndex), assertLength(previousVkMembershipWitness.siblingPath, VK_TREE_HEIGHT), ); - output = await this.proofCreator.createProofInner( - new PrivateKernelInputsInner(previousKernelData, privateCallData), - ); + const proofInput = new PrivateKernelInputsInner(previousKernelData, privateCallData); + pushTestData('private-kernel-inputs-inner', proofInput); + output = await this.proofCreator.createProofInner(proofInput); } (await this.getNewNotes(currentExecution)).forEach(n => { newNotes[n.commitment.toString()] = n; From c9af947ca8f1e7f84e6b1f0e5eed2905ac3a0262 Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 19:34:03 -0300 Subject: [PATCH 05/13] Remove unused placeholder in test name --- .../__snapshots__/noir_test_gen.test.ts.snap | 23 +++++++++++-------- .../src/noir_test_gen.test.ts | 2 +- 2 files changed, 15 insertions(+), 10 deletions(-) diff --git a/yarn-project/noir-protocol-circuits/src/__snapshots__/noir_test_gen.test.ts.snap b/yarn-project/noir-protocol-circuits/src/__snapshots__/noir_test_gen.test.ts.snap index 86437f04b43..84ab3ca87c2 100644 --- a/yarn-project/noir-protocol-circuits/src/__snapshots__/noir_test_gen.test.ts.snap +++ b/yarn-project/noir-protocol-circuits/src/__snapshots__/noir_test_gen.test.ts.snap @@ -4360,12 +4360,12 @@ exports[`Data generation for noir tests Computes a note hash tree 1`] = ` } `; -exports[`Data generation for noir tests Computes contract tree data for %s 1`] = ` +exports[`Data generation for noir tests Computes contract tree data 1`] = ` { - "root": "0x08ccb752b9e4f898ad6b87fb9ca1ed1f2b5e0b6cd67bf083e466ca6a31e21fae", + "root": "0x2d541f5813387a5f4b32d1b3b103447ae142927457a60d00c779a5eeaead471d", "siblingPaths": [ [ - "0x141929db05c4a4803aebc2a4aea0fb2f09a15ae9862c4da49f245b7726f4088e", + "0x0c58a1ae52142f3369f9c46e6717bbef5aa55f9fc0e901a7d8cc860d9467021e", "0x27b1d0839a5b23baf12a8d195b18ac288fcf401afb2f70b8a4b529ede5fa9fed", "0x21dbfd1d029bf447152fcf89e355c334610d1632436ba170f738107266a71550", "0x0bcd1f91cf7bdd471d0a30c58c4706f3fdab3807a954b8f5b5e3bfec87d001bb", @@ -4383,7 +4383,7 @@ exports[`Data generation for noir tests Computes contract tree data for %s 1`] = "0x177b9a10bbee32f77c719c6f8d071a18476cbeb021e155c642bbf93c716ce943", ], [ - "0x0b5dfb998fbdce8e5804992d471c1fc8050642b7aba107e854052eb562944a01", + "0x1ec6c50dc972349d72602ec6887f7accd3174d912ea58629447937865cb88a4d", "0x27b1d0839a5b23baf12a8d195b18ac288fcf401afb2f70b8a4b529ede5fa9fed", "0x21dbfd1d029bf447152fcf89e355c334610d1632436ba170f738107266a71550", "0x0bcd1f91cf7bdd471d0a30c58c4706f3fdab3807a954b8f5b5e3bfec87d001bb", @@ -4408,12 +4408,13 @@ exports[`Data generation for noir tests Computes function tree data for defaultC { "index": 0, "leaf": "0x23590e7237ce1163ade1adba49bf434066481a3bc9098e6751fd1d73e160ca95", - "root": "0x1c55b3903b8b2812ba2a2315edb30aa9b9d9c99c153e9215cc01ec8979a8e9be", + "root": "0x29b35f84dbc19e1588d9b62389b9dd072c4a1da78dad6b1dce9d8cc2657e0863", "siblingPath": [ "0x04d0ae2ba130cedb690c9c9fc41fa1594bac32bfb57b9a7734528295c680b3fa", "0x02996203377fc96b38fd41a1f65ddce2b26247fee321a12e58b457ee08621a14", "0x0837a67313f4dbbd8d6971c0672f961f0a3b9e218c1395d327915209292acbbf", "0x2e0ef36ddc5db29acb6ef904999046f835ce7c78a40c3f7a0edb03b2f917a765", + "0x1a9fdb505152f9c2baaffe4a30ee80775b58ebf8c2dde76435835b085c6f70ca", ], } `; @@ -4422,12 +4423,13 @@ exports[`Data generation for noir tests Computes function tree data for defaultC { "index": 1, "leaf": "0x04d0ae2ba130cedb690c9c9fc41fa1594bac32bfb57b9a7734528295c680b3fa", - "root": "0x1c55b3903b8b2812ba2a2315edb30aa9b9d9c99c153e9215cc01ec8979a8e9be", + "root": "0x29b35f84dbc19e1588d9b62389b9dd072c4a1da78dad6b1dce9d8cc2657e0863", "siblingPath": [ "0x23590e7237ce1163ade1adba49bf434066481a3bc9098e6751fd1d73e160ca95", "0x02996203377fc96b38fd41a1f65ddce2b26247fee321a12e58b457ee08621a14", "0x0837a67313f4dbbd8d6971c0672f961f0a3b9e218c1395d327915209292acbbf", "0x2e0ef36ddc5db29acb6ef904999046f835ce7c78a40c3f7a0edb03b2f917a765", + "0x1a9fdb505152f9c2baaffe4a30ee80775b58ebf8c2dde76435835b085c6f70ca", ], } `; @@ -4436,12 +4438,13 @@ exports[`Data generation for noir tests Computes function tree data for defaultC { "index": 2, "leaf": "0x1fc20a5f4a9bf052ae4fee30281fd09908a25063c749bc35939502ffaeaee8c2", - "root": "0x1c55b3903b8b2812ba2a2315edb30aa9b9d9c99c153e9215cc01ec8979a8e9be", + "root": "0x29b35f84dbc19e1588d9b62389b9dd072c4a1da78dad6b1dce9d8cc2657e0863", "siblingPath": [ "0x2d72ef5ebb7c974e1f5a8bed092f1cf1bf0a0cb1eda28516221ca7e5811ecf15", "0x1bed44f12632c0a6343cd886bd3e548bb5e8d2fd35fe9bc81f28defd4ed885b0", "0x0837a67313f4dbbd8d6971c0672f961f0a3b9e218c1395d327915209292acbbf", "0x2e0ef36ddc5db29acb6ef904999046f835ce7c78a40c3f7a0edb03b2f917a765", + "0x1a9fdb505152f9c2baaffe4a30ee80775b58ebf8c2dde76435835b085c6f70ca", ], } `; @@ -4450,12 +4453,13 @@ exports[`Data generation for noir tests Computes function tree data for defaultC { "index": 3, "leaf": "0x2d72ef5ebb7c974e1f5a8bed092f1cf1bf0a0cb1eda28516221ca7e5811ecf15", - "root": "0x1c55b3903b8b2812ba2a2315edb30aa9b9d9c99c153e9215cc01ec8979a8e9be", + "root": "0x29b35f84dbc19e1588d9b62389b9dd072c4a1da78dad6b1dce9d8cc2657e0863", "siblingPath": [ "0x1fc20a5f4a9bf052ae4fee30281fd09908a25063c749bc35939502ffaeaee8c2", "0x1bed44f12632c0a6343cd886bd3e548bb5e8d2fd35fe9bc81f28defd4ed885b0", "0x0837a67313f4dbbd8d6971c0672f961f0a3b9e218c1395d327915209292acbbf", "0x2e0ef36ddc5db29acb6ef904999046f835ce7c78a40c3f7a0edb03b2f917a765", + "0x1a9fdb505152f9c2baaffe4a30ee80775b58ebf8c2dde76435835b085c6f70ca", ], } `; @@ -4464,12 +4468,13 @@ exports[`Data generation for noir tests Computes function tree data for parentCo { "index": 0, "leaf": "0x2a5e01a1782ba31fa1c2e2619ec412182cd8aa4749c0b90e76f13c54ab8f890e", - "root": "0x02b3f6b0a36bd01f08cee2d607dbe08894bb8c58159e87bb17db28cad43291d4", + "root": "0x1051b0295ee46562e09383e4bb819268f60b3d058724a2adcac2049997d8f3f4", "siblingPath": [ "0x1f2e3193c7187347a099ee7cb5d6ac077da6b18706fe5508e658a3d0a05494f7", "0x2350c7d2f19119502d073142ff019af884d6513f38b92d5119b4999502282247", "0x0837a67313f4dbbd8d6971c0672f961f0a3b9e218c1395d327915209292acbbf", "0x2e0ef36ddc5db29acb6ef904999046f835ce7c78a40c3f7a0edb03b2f917a765", + "0x1a9fdb505152f9c2baaffe4a30ee80775b58ebf8c2dde76435835b085c6f70ca", ], } `; diff --git a/yarn-project/noir-protocol-circuits/src/noir_test_gen.test.ts b/yarn-project/noir-protocol-circuits/src/noir_test_gen.test.ts index aada805f27a..ecb37e3a8d2 100644 --- a/yarn-project/noir-protocol-circuits/src/noir_test_gen.test.ts +++ b/yarn-project/noir-protocol-circuits/src/noir_test_gen.test.ts @@ -65,7 +65,7 @@ describe('Data generation for noir tests', () => { }); }); - test('Computes contract tree data for %s', async () => { + test('Computes contract tree data', async () => { const leaves = contracts.map(([contract]) => { const contractLeaf = computeContractLeaf( new NewContractData(contract.address, contract.portalContractAddress, contract.functionTreeRoot), From 70ad0fee534292e07eb197f8cfb2f96440e7325f Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 19:34:42 -0300 Subject: [PATCH 06/13] Unhardcode lengths in private circuit public inputs in noir-circuits type conversions --- .../src/type_conversion.ts | 49 ++++++++++++++----- 1 file changed, 37 insertions(+), 12 deletions(-) diff --git a/yarn-project/noir-protocol-circuits/src/type_conversion.ts b/yarn-project/noir-protocol-circuits/src/type_conversion.ts index e42a3cceb56..020d53bfb97 100644 --- a/yarn-project/noir-protocol-circuits/src/type_conversion.ts +++ b/yarn-project/noir-protocol-circuits/src/type_conversion.ts @@ -16,6 +16,7 @@ import { ContractStorageRead, ContractStorageUpdateRequest, EthAddress, + FUNCTION_TREE_HEIGHT, FinalAccumulatedData, Fr, FunctionData, @@ -23,20 +24,28 @@ import { GlobalVariables, KernelCircuitPublicInputs, KernelCircuitPublicInputsFinal, + MAX_NEW_COMMITMENTS_PER_CALL, MAX_NEW_COMMITMENTS_PER_TX, MAX_NEW_CONTRACTS_PER_TX, + MAX_NEW_L2_TO_L1_MSGS_PER_CALL, MAX_NEW_L2_TO_L1_MSGS_PER_TX, + MAX_NEW_NULLIFIERS_PER_CALL, MAX_NEW_NULLIFIERS_PER_TX, MAX_OPTIONALLY_REVEALED_DATA_LENGTH_PER_TX, + MAX_PENDING_READ_REQUESTS_PER_CALL, MAX_PENDING_READ_REQUESTS_PER_TX, + MAX_PRIVATE_CALL_STACK_LENGTH_PER_CALL, MAX_PRIVATE_CALL_STACK_LENGTH_PER_TX, + MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL, MAX_PUBLIC_CALL_STACK_LENGTH_PER_TX, MAX_PUBLIC_DATA_READS_PER_TX, MAX_PUBLIC_DATA_UPDATE_REQUESTS_PER_TX, + MAX_READ_REQUESTS_PER_CALL, MAX_READ_REQUESTS_PER_TX, MembershipWitness, MergeRollupInputs, NULLIFIER_TREE_HEIGHT, + NUM_FIELDS_PER_SHA256, NewContractData, NullifierLeafPreimage, OptionallyRevealedData, @@ -55,6 +64,7 @@ import { PublicDataRead, PublicDataUpdateRequest, PublicKernelInputs, + RETURN_VALUES_LENGTH, ReadRequestMembershipWitness, RootRollupInputs, RootRollupPublicInputs, @@ -481,33 +491,48 @@ export function mapPrivateCircuitPublicInputsToNoir( return { call_context: mapCallContextToNoir(privateCircuitPublicInputs.callContext), args_hash: mapFieldToNoir(privateCircuitPublicInputs.argsHash), - return_values: privateCircuitPublicInputs.returnValues.map(mapFieldToNoir) as FixedLengthArray, - read_requests: privateCircuitPublicInputs.readRequests.map(mapFieldToNoir) as FixedLengthArray, + return_values: privateCircuitPublicInputs.returnValues.map(mapFieldToNoir) as FixedLengthArray< + NoirField, + typeof RETURN_VALUES_LENGTH + >, + read_requests: privateCircuitPublicInputs.readRequests.map(mapFieldToNoir) as FixedLengthArray< + NoirField, + typeof MAX_READ_REQUESTS_PER_CALL + >, pending_read_requests: privateCircuitPublicInputs.pendingReadRequests.map(mapFieldToNoir) as FixedLengthArray< NoirField, - 32 + typeof MAX_PENDING_READ_REQUESTS_PER_CALL + >, + new_commitments: privateCircuitPublicInputs.newCommitments.map(mapFieldToNoir) as FixedLengthArray< + NoirField, + typeof MAX_NEW_COMMITMENTS_PER_CALL + >, + new_nullifiers: privateCircuitPublicInputs.newNullifiers.map(mapFieldToNoir) as FixedLengthArray< + NoirField, + typeof MAX_NEW_NULLIFIERS_PER_CALL >, - new_commitments: privateCircuitPublicInputs.newCommitments.map(mapFieldToNoir) as FixedLengthArray, - new_nullifiers: privateCircuitPublicInputs.newNullifiers.map(mapFieldToNoir) as FixedLengthArray, nullified_commitments: privateCircuitPublicInputs.nullifiedCommitments.map(mapFieldToNoir) as FixedLengthArray< NoirField, - 16 + typeof MAX_NEW_NULLIFIERS_PER_CALL >, private_call_stack_hashes: privateCircuitPublicInputs.privateCallStackHashes.map( mapFieldToNoir, - ) as FixedLengthArray, + ) as FixedLengthArray, public_call_stack_hashes: privateCircuitPublicInputs.publicCallStackHashes.map(mapFieldToNoir) as FixedLengthArray< NoirField, - 4 + typeof MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL + >, + new_l2_to_l1_msgs: privateCircuitPublicInputs.newL2ToL1Msgs.map(mapFieldToNoir) as FixedLengthArray< + NoirField, + typeof MAX_NEW_L2_TO_L1_MSGS_PER_CALL >, - new_l2_to_l1_msgs: privateCircuitPublicInputs.newL2ToL1Msgs.map(mapFieldToNoir) as FixedLengthArray, encrypted_logs_hash: privateCircuitPublicInputs.encryptedLogsHash.map(mapFieldToNoir) as FixedLengthArray< NoirField, - 2 + typeof NUM_FIELDS_PER_SHA256 >, unencrypted_logs_hash: privateCircuitPublicInputs.unencryptedLogsHash.map(mapFieldToNoir) as FixedLengthArray< NoirField, - 2 + typeof NUM_FIELDS_PER_SHA256 >, encrypted_log_preimages_length: mapFieldToNoir(privateCircuitPublicInputs.encryptedLogPreimagesLength), unencrypted_log_preimages_length: mapFieldToNoir(privateCircuitPublicInputs.unencryptedLogPreimagesLength), @@ -538,7 +563,7 @@ export function mapPrivateCallStackItemToNoir(privateCallStackItem: PrivateCallS * @returns The noir function leaf membership witness. */ function mapFunctionLeafMembershipWitnessToNoir( - membershipWitness: MembershipWitness<4>, + membershipWitness: MembershipWitness, ): FunctionLeafMembershipWitnessNoir { return { leaf_index: membershipWitness.leafIndex.toString(), From 917fa5a352069cc20f59920f9e7aa6cb7e040bf0 Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 19:34:57 -0300 Subject: [PATCH 07/13] Update contract functions from snapshot --- .../src/crates/types/src/tests/fixtures/contract_functions.nr | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/yarn-project/noir-protocol-circuits/src/crates/types/src/tests/fixtures/contract_functions.nr b/yarn-project/noir-protocol-circuits/src/crates/types/src/tests/fixtures/contract_functions.nr index ba1dad9aa7d..0e81392c885 100644 --- a/yarn-project/noir-protocol-circuits/src/crates/types/src/tests/fixtures/contract_functions.nr +++ b/yarn-project/noir-protocol-circuits/src/crates/types/src/tests/fixtures/contract_functions.nr @@ -41,6 +41,7 @@ global default_private_function = ContractFunction { 0x02996203377fc96b38fd41a1f65ddce2b26247fee321a12e58b457ee08621a14, 0x0837a67313f4dbbd8d6971c0672f961f0a3b9e218c1395d327915209292acbbf, 0x2e0ef36ddc5db29acb6ef904999046f835ce7c78a40c3f7a0edb03b2f917a765, + 0x1a9fdb505152f9c2baaffe4a30ee80775b58ebf8c2dde76435835b085c6f70ca, ], }, }; @@ -61,6 +62,7 @@ global default_internal_private_function = ContractFunction { 0x02996203377fc96b38fd41a1f65ddce2b26247fee321a12e58b457ee08621a14, 0x0837a67313f4dbbd8d6971c0672f961f0a3b9e218c1395d327915209292acbbf, 0x2e0ef36ddc5db29acb6ef904999046f835ce7c78a40c3f7a0edb03b2f917a765, + 0x1a9fdb505152f9c2baaffe4a30ee80775b58ebf8c2dde76435835b085c6f70ca, ], }, }; @@ -81,6 +83,7 @@ global default_public_function = ContractFunction { 0x1bed44f12632c0a6343cd886bd3e548bb5e8d2fd35fe9bc81f28defd4ed885b0, 0x0837a67313f4dbbd8d6971c0672f961f0a3b9e218c1395d327915209292acbbf, 0x2e0ef36ddc5db29acb6ef904999046f835ce7c78a40c3f7a0edb03b2f917a765, + 0x1a9fdb505152f9c2baaffe4a30ee80775b58ebf8c2dde76435835b085c6f70ca, ], }, }; @@ -101,6 +104,7 @@ global default_internal_public_function = ContractFunction { 0x1bed44f12632c0a6343cd886bd3e548bb5e8d2fd35fe9bc81f28defd4ed885b0, 0x0837a67313f4dbbd8d6971c0672f961f0a3b9e218c1395d327915209292acbbf, 0x2e0ef36ddc5db29acb6ef904999046f835ce7c78a40c3f7a0edb03b2f917a765, + 0x1a9fdb505152f9c2baaffe4a30ee80775b58ebf8c2dde76435835b085c6f70ca, ], }, }; From 1f40181c294996db9d664db91f6dfc2e9ef5b057 Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 19:35:31 -0300 Subject: [PATCH 08/13] Fix bug in Field that caused string output to be decimal instead of hex while 0x-prefixed --- yarn-project/foundation/src/fields/fields.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/yarn-project/foundation/src/fields/fields.ts b/yarn-project/foundation/src/fields/fields.ts index 1c2069169af..591b57f6892 100644 --- a/yarn-project/foundation/src/fields/fields.ts +++ b/yarn-project/foundation/src/fields/fields.ts @@ -41,8 +41,13 @@ abstract class BaseField { protected constructor(value: number | bigint | boolean | BaseField | Buffer) { if (value instanceof Buffer) { + if (value.length > BaseField.SIZE_IN_BYTES) { + throw new Error(`Value length ${value.length} exceeds ${BaseField.SIZE_IN_BYTES}`); + } this.asBuffer = - value.length === 32 ? value : Buffer.concat([Buffer.alloc(BaseField.SIZE_IN_BYTES - value.length), value]); + value.length === BaseField.SIZE_IN_BYTES + ? value + : Buffer.concat([Buffer.alloc(BaseField.SIZE_IN_BYTES - value.length), value]); } else if (typeof value === 'bigint' || typeof value === 'number' || typeof value === 'boolean') { this.asBigInt = BigInt(value); if (this.asBigInt >= this.modulus()) { @@ -104,7 +109,7 @@ abstract class BaseField { } toFriendlyJSON(): string { - return `0x${this.toBigInt().toString()}`; + return this.toString(); } toField() { From 929b1cbfa3cc28eb70ff4d403c42330a7af96901 Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 19:35:52 -0300 Subject: [PATCH 09/13] Allow cli deploy to output in json format and use it to load deployment address in quickstart --- yarn-project/cli/src/index.ts | 28 +++++++++++++++---- yarn-project/end-to-end/Dockerfile | 1 + .../end-to-end/src/guides/up_quick_start.sh | 15 +++------- 3 files changed, 27 insertions(+), 17 deletions(-) diff --git a/yarn-project/cli/src/index.ts b/yarn-project/cli/src/index.ts index e99d6f640db..629efbe4eaa 100644 --- a/yarn-project/cli/src/index.ts +++ b/yarn-project/cli/src/index.ts @@ -73,6 +73,7 @@ export function getProgram(log: LogFn, debugLogger: DebugLogger): Command { const packageJsonPath = resolve(dirname(fileURLToPath(import.meta.url)), '../package.json'); const cliVersion: string = JSON.parse(readFileSync(packageJsonPath).toString()).version; + const logJson = (obj: object) => log(JSON.stringify(obj, null, 2)); program.name('aztec-cli').description('CLI for interacting with Aztec.').version(cliVersion); @@ -242,10 +243,11 @@ export function getProgram(log: LogFn, debugLogger: DebugLogger): Command { 'Optional deployment salt as a hex string for generating the deployment address.', parseSaltFromHexString, ) + .option('--json', 'Emit output as json') // `options.wait` is default true. Passing `--no-wait` will set it to false. // https://github.com/tj/commander.js#other-option-types-negatable-boolean-and-booleanvalue .option('--no-wait', 'Skip waiting for the contract to be deployed. Print the hash of deployment transaction') - .action(async (artifactPath, { rpcUrl, publicKey, args: rawArgs, portalAddress, salt, wait }) => { + .action(async (artifactPath, { json, rpcUrl, publicKey, args: rawArgs, portalAddress, salt, wait }) => { const contractArtifact = await getContractArtifact(artifactPath, log); const constructorArtifact = contractArtifact.functions.find(({ name }) => name === 'constructor'); @@ -277,12 +279,26 @@ export function getProgram(log: LogFn, debugLogger: DebugLogger): Command { debugLogger(`Deploy tx sent with hash ${txHash}`); if (wait) { const deployed = await tx.wait(); - log(`\nContract deployed at ${deployed.contract.completeAddress.address.toString()}\n`); - log(`Contract partial address ${deployed.contract.completeAddress.partialAddress.toString()}\n`); + const { address, partialAddress } = deployed.contract.completeAddress; + if (json) { + logJson({ address: address.toString(), partialAddress: partialAddress.toString() }); + } else { + log(`\nContract deployed at ${address.toString()}\n`); + log(`Contract partial address ${partialAddress.toString()}\n`); + } } else { - log(`\nContract Address: ${deploy.completeAddress?.address.toString() ?? 'N/A'}`); - log(`Contract Partial Address: ${deploy.completeAddress?.partialAddress.toString() ?? 'N/A'}`); - log(`Deployment transaction hash: ${txHash}\n`); + const { address, partialAddress } = deploy.completeAddress ?? {}; + if (json) { + logJson({ + address: address?.toString() ?? 'N/A', + partialAddress: partialAddress?.toString() ?? 'N/A', + txHash: txHash.toString(), + }); + } else { + log(`\nContract Address: ${deploy.completeAddress?.address.toString() ?? 'N/A'}`); + log(`Contract Partial Address: ${deploy.completeAddress?.partialAddress.toString() ?? 'N/A'}`); + log(`Deployment transaction hash: ${txHash}\n`); + } } }); diff --git a/yarn-project/end-to-end/Dockerfile b/yarn-project/end-to-end/Dockerfile index 15f21a82149..915eb134e5e 100644 --- a/yarn-project/end-to-end/Dockerfile +++ b/yarn-project/end-to-end/Dockerfile @@ -12,6 +12,7 @@ RUN yarn cache clean && yarn workspaces focus --production # TODO: Not very minimal as chromium adds about 500MB of bloat :/ Separate or install at test runtime? FROM node:18-alpine RUN apk update && apk add --no-cache \ + jq \ bash \ chromium \ chromium-chromedriver \ diff --git a/yarn-project/end-to-end/src/guides/up_quick_start.sh b/yarn-project/end-to-end/src/guides/up_quick_start.sh index ddb1edfb735..9181b8d6aa7 100755 --- a/yarn-project/end-to-end/src/guides/up_quick_start.sh +++ b/yarn-project/end-to-end/src/guides/up_quick_start.sh @@ -4,23 +4,16 @@ set -eux # The following accounts and pks must match the ones exposed by the sandbox. -# This test also requires that no other transactions have been sent to the sandbox -# so the contract address hardcoded into $CONTRACT is correct. Otherwise, we'd need -# to extract the deployed address from the cli `deploy` command. # docs:start:declare-accounts -ALICE="0x29e53e3e43377c80c8a1e390ed90ddf1167f376c4c063844ec18f8a81516c1c0" -BOB="0x2b66c968c3ae3b827b6614719141be12667bad86f13b401c667d64a7c56d911c" +ALICE="0x06357cc85cb8fc561adbf741f63cd75efa26ffba1c80d431ec77d036d8edf022" +BOB="0x1b18a972d54db0283a04abaace5f7b03c3fca5a4b2c0cf113b457de6ea4991e7" ALICE_PRIVATE_KEY="0x2153536ff6628eee01cf4024889ff977a18d9fa61d0e414422f7681cf085c281" # docs:end:declare-accounts # docs:start:deploy -aztec-cli deploy \ - TokenContractArtifact \ - --salt 0 \ - --args $ALICE - -CONTRACT="0x18a018014978f3a6b8f69548fbfc5fded6b829b36becea24dd7f7ee34927dff7" +CONTRACT=$(aztec-cli deploy TokenContractArtifact --salt 0 --args $ALICE --json | jq -r '.address') +echo "Deployed contract at $CONTRACT" aztec-cli check-deploy --contract-address $CONTRACT # docs:end:deploy From e8a1168d7bdf1b74bb235368a1ebf2c33e9a98eb Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 19:49:52 -0300 Subject: [PATCH 10/13] Update snapshot from circuits.js --- .../src/abis/__snapshots__/abis.test.ts.snap | 64 +++++++++---------- 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/yarn-project/circuits.js/src/abis/__snapshots__/abis.test.ts.snap b/yarn-project/circuits.js/src/abis/__snapshots__/abis.test.ts.snap index f297d6a2a49..71d1cdce74a 100644 --- a/yarn-project/circuits.js/src/abis/__snapshots__/abis.test.ts.snap +++ b/yarn-project/circuits.js/src/abis/__snapshots__/abis.test.ts.snap @@ -612,41 +612,41 @@ Fr { exports[`abis computes function tree root 1`] = ` Fr { - "asBigInt": 21090938391652199999535994101952511109725456907725564751008805452452294036010n, + "asBigInt": 18902231782334398705464257251364974449663398212058621439366133672872128659209n, "asBuffer": { "data": [ - 46, - 161, - 12, - 80, - 15, - 148, - 101, - 167, - 237, - 48, - 42, - 247, + 41, + 202, + 72, + 183, + 227, + 53, + 212, + 51, + 133, + 173, + 223, + 25, + 183, + 14, 155, - 146, - 117, - 106, - 78, - 36, - 159, - 144, - 106, - 160, - 190, - 170, - 211, - 213, - 47, - 102, - 180, - 244, - 10, - 42, + 5, + 105, + 58, + 143, + 86, + 204, + 9, + 239, + 140, + 187, + 195, + 116, + 164, + 13, + 173, + 191, + 9, ], "type": "Buffer", }, From 5d8c7b809d94f391f952ae810779db5ed4bb0e35 Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 20:09:39 -0300 Subject: [PATCH 11/13] Regen types for noir-protocol-circuits --- .../src/types/private_kernel_init_types.ts | 2 +- .../src/types/private_kernel_inner_types.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/yarn-project/noir-protocol-circuits/src/types/private_kernel_init_types.ts b/yarn-project/noir-protocol-circuits/src/types/private_kernel_init_types.ts index af47e9d082f..d5beb0d9ab4 100644 --- a/yarn-project/noir-protocol-circuits/src/types/private_kernel_init_types.ts +++ b/yarn-project/noir-protocol-circuits/src/types/private_kernel_init_types.ts @@ -126,7 +126,7 @@ export interface VerificationKey {} export interface FunctionLeafMembershipWitness { leaf_index: Field; - sibling_path: FixedLengthArray; + sibling_path: FixedLengthArray; } export interface ContractLeafMembershipWitness { diff --git a/yarn-project/noir-protocol-circuits/src/types/private_kernel_inner_types.ts b/yarn-project/noir-protocol-circuits/src/types/private_kernel_inner_types.ts index 935af55a122..2666c692e66 100644 --- a/yarn-project/noir-protocol-circuits/src/types/private_kernel_inner_types.ts +++ b/yarn-project/noir-protocol-circuits/src/types/private_kernel_inner_types.ts @@ -188,7 +188,7 @@ export interface PrivateCallStackItem { export interface FunctionLeafMembershipWitness { leaf_index: Field; - sibling_path: FixedLengthArray; + sibling_path: FixedLengthArray; } export interface ContractLeafMembershipWitness { From 708cddf89d6317373b9df0a56a97405e2100b4fb Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 20:10:18 -0300 Subject: [PATCH 12/13] Remove explicit type casts and magic numbers from noir circuits type conversions --- .../src/type_conversion.ts | 272 ++++++------------ 1 file changed, 89 insertions(+), 183 deletions(-) diff --git a/yarn-project/noir-protocol-circuits/src/type_conversion.ts b/yarn-project/noir-protocol-circuits/src/type_conversion.ts index 020d53bfb97..b4f5352c688 100644 --- a/yarn-project/noir-protocol-circuits/src/type_conversion.ts +++ b/yarn-project/noir-protocol-circuits/src/type_conversion.ts @@ -6,6 +6,7 @@ import { BaseOrMergeRollupPublicInputs, BaseRollupInputs, BlockHeader, + CONTRACT_TREE_HEIGHT, CallContext, CallRequest, CallerContext, @@ -24,23 +25,16 @@ import { GlobalVariables, KernelCircuitPublicInputs, KernelCircuitPublicInputsFinal, - MAX_NEW_COMMITMENTS_PER_CALL, MAX_NEW_COMMITMENTS_PER_TX, MAX_NEW_CONTRACTS_PER_TX, - MAX_NEW_L2_TO_L1_MSGS_PER_CALL, MAX_NEW_L2_TO_L1_MSGS_PER_TX, - MAX_NEW_NULLIFIERS_PER_CALL, MAX_NEW_NULLIFIERS_PER_TX, MAX_OPTIONALLY_REVEALED_DATA_LENGTH_PER_TX, - MAX_PENDING_READ_REQUESTS_PER_CALL, MAX_PENDING_READ_REQUESTS_PER_TX, - MAX_PRIVATE_CALL_STACK_LENGTH_PER_CALL, MAX_PRIVATE_CALL_STACK_LENGTH_PER_TX, - MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL, MAX_PUBLIC_CALL_STACK_LENGTH_PER_TX, MAX_PUBLIC_DATA_READS_PER_TX, MAX_PUBLIC_DATA_UPDATE_REQUESTS_PER_TX, - MAX_READ_REQUESTS_PER_CALL, MAX_READ_REQUESTS_PER_TX, MembershipWitness, MergeRollupInputs, @@ -49,6 +43,7 @@ import { NewContractData, NullifierLeafPreimage, OptionallyRevealedData, + PUBLIC_DATA_TREE_HEIGHT, Point, PreviousKernelData, PreviousRollupData, @@ -64,14 +59,13 @@ import { PublicDataRead, PublicDataUpdateRequest, PublicKernelInputs, - RETURN_VALUES_LENGTH, ReadRequestMembershipWitness, RootRollupInputs, RootRollupPublicInputs, TxContext, TxRequest, } from '@aztec/circuits.js'; -import { Tuple } from '@aztec/foundation/serialize'; +import { Tuple, mapTuple } from '@aztec/foundation/serialize'; import { BlockHeader as BlockHeaderNoir, @@ -82,7 +76,6 @@ import { CombinedConstantData as CombinedConstantDataNoir, ContractDeploymentData as ContractDeploymentDataNoir, ContractLeafMembershipWitness as ContractLeafMembershipWitnessNoir, - FixedLengthArray, FunctionData as FunctionDataNoir, FunctionLeafMembershipWitness as FunctionLeafMembershipWitnessNoir, FunctionSelector as FunctionSelectorNoir, @@ -491,49 +484,17 @@ export function mapPrivateCircuitPublicInputsToNoir( return { call_context: mapCallContextToNoir(privateCircuitPublicInputs.callContext), args_hash: mapFieldToNoir(privateCircuitPublicInputs.argsHash), - return_values: privateCircuitPublicInputs.returnValues.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof RETURN_VALUES_LENGTH - >, - read_requests: privateCircuitPublicInputs.readRequests.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof MAX_READ_REQUESTS_PER_CALL - >, - pending_read_requests: privateCircuitPublicInputs.pendingReadRequests.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof MAX_PENDING_READ_REQUESTS_PER_CALL - >, - new_commitments: privateCircuitPublicInputs.newCommitments.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof MAX_NEW_COMMITMENTS_PER_CALL - >, - new_nullifiers: privateCircuitPublicInputs.newNullifiers.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof MAX_NEW_NULLIFIERS_PER_CALL - >, - nullified_commitments: privateCircuitPublicInputs.nullifiedCommitments.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof MAX_NEW_NULLIFIERS_PER_CALL - >, - private_call_stack_hashes: privateCircuitPublicInputs.privateCallStackHashes.map( - mapFieldToNoir, - ) as FixedLengthArray, - public_call_stack_hashes: privateCircuitPublicInputs.publicCallStackHashes.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL - >, - new_l2_to_l1_msgs: privateCircuitPublicInputs.newL2ToL1Msgs.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof MAX_NEW_L2_TO_L1_MSGS_PER_CALL - >, - encrypted_logs_hash: privateCircuitPublicInputs.encryptedLogsHash.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof NUM_FIELDS_PER_SHA256 - >, - unencrypted_logs_hash: privateCircuitPublicInputs.unencryptedLogsHash.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof NUM_FIELDS_PER_SHA256 - >, + return_values: mapTuple(privateCircuitPublicInputs.returnValues, mapFieldToNoir), + read_requests: mapTuple(privateCircuitPublicInputs.readRequests, mapFieldToNoir), + pending_read_requests: mapTuple(privateCircuitPublicInputs.pendingReadRequests, mapFieldToNoir), + new_commitments: mapTuple(privateCircuitPublicInputs.newCommitments, mapFieldToNoir), + new_nullifiers: mapTuple(privateCircuitPublicInputs.newNullifiers, mapFieldToNoir), + nullified_commitments: mapTuple(privateCircuitPublicInputs.nullifiedCommitments, mapFieldToNoir), + private_call_stack_hashes: mapTuple(privateCircuitPublicInputs.privateCallStackHashes, mapFieldToNoir), + public_call_stack_hashes: mapTuple(privateCircuitPublicInputs.publicCallStackHashes, mapFieldToNoir), + new_l2_to_l1_msgs: mapTuple(privateCircuitPublicInputs.newL2ToL1Msgs, mapFieldToNoir), + encrypted_logs_hash: mapTuple(privateCircuitPublicInputs.encryptedLogsHash, mapFieldToNoir), + unencrypted_logs_hash: mapTuple(privateCircuitPublicInputs.unencryptedLogsHash, mapFieldToNoir), encrypted_log_preimages_length: mapFieldToNoir(privateCircuitPublicInputs.encryptedLogPreimagesLength), unencrypted_log_preimages_length: mapFieldToNoir(privateCircuitPublicInputs.unencryptedLogPreimagesLength), block_header: mapBlockHeaderToNoir(privateCircuitPublicInputs.blockHeader), @@ -567,7 +528,7 @@ function mapFunctionLeafMembershipWitnessToNoir( ): FunctionLeafMembershipWitnessNoir { return { leaf_index: membershipWitness.leafIndex.toString(), - sibling_path: membershipWitness.siblingPath.map(mapFieldToNoir) as FixedLengthArray, + sibling_path: mapTuple(membershipWitness.siblingPath, mapFieldToNoir), }; } @@ -577,11 +538,11 @@ function mapFunctionLeafMembershipWitnessToNoir( * @returns The noir contract leaf membership witness. */ function mapContractLeafMembershipWitnessToNoir( - membershipWitness: MembershipWitness<16>, + membershipWitness: MembershipWitness, ): ContractLeafMembershipWitnessNoir { return { leaf_index: membershipWitness.leafIndex.toString(), - sibling_path: membershipWitness.siblingPath.map(mapFieldToNoir) as FixedLengthArray, + sibling_path: mapTuple(membershipWitness.siblingPath, mapFieldToNoir), }; } @@ -595,7 +556,7 @@ export function mapReadRequestMembershipWitnessToNoir( ): ReadRequestMembershipWitnessNoir { return { leaf_index: mapFieldToNoir(readRequestMembershipWitness.leafIndex), - sibling_path: readRequestMembershipWitness.siblingPath.map(mapFieldToNoir) as FixedLengthArray, + sibling_path: mapTuple(readRequestMembershipWitness.siblingPath, mapFieldToNoir), is_transient: readRequestMembershipWitness.isTransient, hint_to_commitment: mapFieldToNoir(readRequestMembershipWitness.hintToCommitment), }; @@ -609,14 +570,8 @@ export function mapReadRequestMembershipWitnessToNoir( export function mapPrivateCallDataToNoir(privateCallData: PrivateCallData): PrivateCallDataNoir { return { call_stack_item: mapPrivateCallStackItemToNoir(privateCallData.callStackItem), - private_call_stack: privateCallData.privateCallStack.map(mapCallRequestToNoir) as FixedLengthArray< - CallRequestNoir, - 4 - >, - public_call_stack: privateCallData.publicCallStack.map(mapCallRequestToNoir) as FixedLengthArray< - CallRequestNoir, - 4 - >, + private_call_stack: mapTuple(privateCallData.privateCallStack, mapCallRequestToNoir), + public_call_stack: mapTuple(privateCallData.publicCallStack, mapCallRequestToNoir), proof: {}, vk: {}, function_leaf_membership_witness: mapFunctionLeafMembershipWitnessToNoir( @@ -625,9 +580,10 @@ export function mapPrivateCallDataToNoir(privateCallData: PrivateCallData): Priv contract_leaf_membership_witness: mapContractLeafMembershipWitnessToNoir( privateCallData.contractLeafMembershipWitness, ), - read_request_membership_witnesses: privateCallData.readRequestMembershipWitnesses.map( + read_request_membership_witnesses: mapTuple( + privateCallData.readRequestMembershipWitnesses, mapReadRequestMembershipWitnessToNoir, - ) as FixedLengthArray, + ), //TODO this seems like the wrong type in circuits.js portal_contract_address: mapEthAddressToNoir(EthAddress.fromField(privateCallData.portalContractAddress)), acir_hash: mapFieldToNoir(privateCallData.acirHash), @@ -796,8 +752,8 @@ export function mapCombinedAccumulatedDataFromNoir( mapCallRequestFromNoir, ), mapTupleFromNoir(combinedAccumulatedData.new_l2_to_l1_msgs, MAX_NEW_L2_TO_L1_MSGS_PER_TX, mapFieldFromNoir), - mapTupleFromNoir(combinedAccumulatedData.encrypted_logs_hash, 2, mapFieldFromNoir), - mapTupleFromNoir(combinedAccumulatedData.unencrypted_logs_hash, 2, mapFieldFromNoir), + mapTupleFromNoir(combinedAccumulatedData.encrypted_logs_hash, NUM_FIELDS_PER_SHA256, mapFieldFromNoir), + mapTupleFromNoir(combinedAccumulatedData.unencrypted_logs_hash, NUM_FIELDS_PER_SHA256, mapFieldFromNoir), mapFieldFromNoir(combinedAccumulatedData.encrypted_log_preimages_length), mapFieldFromNoir(combinedAccumulatedData.unencrypted_log_preimages_length), mapTupleFromNoir(combinedAccumulatedData.new_contracts, MAX_NEW_CONTRACTS_PER_TX, mapNewContractDataFromNoir), @@ -842,8 +798,8 @@ export function mapFinalAccumulatedDataFromNoir(finalAccumulatedData: FinalAccum mapCallRequestFromNoir, ), mapTupleFromNoir(finalAccumulatedData.new_l2_to_l1_msgs, MAX_NEW_L2_TO_L1_MSGS_PER_TX, mapFieldFromNoir), - mapTupleFromNoir(finalAccumulatedData.encrypted_logs_hash, 2, mapFieldFromNoir), - mapTupleFromNoir(finalAccumulatedData.unencrypted_logs_hash, 2, mapFieldFromNoir), + mapTupleFromNoir(finalAccumulatedData.encrypted_logs_hash, NUM_FIELDS_PER_SHA256, mapFieldFromNoir), + mapTupleFromNoir(finalAccumulatedData.unencrypted_logs_hash, NUM_FIELDS_PER_SHA256, mapFieldFromNoir), mapFieldFromNoir(finalAccumulatedData.encrypted_log_preimages_length), mapFieldFromNoir(finalAccumulatedData.unencrypted_log_preimages_length), mapTupleFromNoir(finalAccumulatedData.new_contracts, MAX_NEW_CONTRACTS_PER_TX, mapNewContractDataFromNoir), @@ -865,50 +821,25 @@ export function mapCombinedAccumulatedDataToNoir( ): CombinedAccumulatedDataNoir { return { aggregation_object: {}, - read_requests: combinedAccumulatedData.readRequests.map(mapFieldToNoir) as FixedLengthArray, - pending_read_requests: combinedAccumulatedData.pendingReadRequests.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - 128 - >, - new_commitments: combinedAccumulatedData.newCommitments.map(mapFieldToNoir) as FixedLengthArray, - new_nullifiers: combinedAccumulatedData.newNullifiers.map(mapFieldToNoir) as FixedLengthArray, - nullified_commitments: combinedAccumulatedData.nullifiedCommitments.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - 64 - >, - private_call_stack: combinedAccumulatedData.privateCallStack.map(mapCallRequestToNoir) as FixedLengthArray< - CallRequestNoir, - 8 - >, - public_call_stack: combinedAccumulatedData.publicCallStack.map(mapCallRequestToNoir) as FixedLengthArray< - CallRequestNoir, - 8 - >, - new_l2_to_l1_msgs: combinedAccumulatedData.newL2ToL1Msgs.map(mapFieldToNoir) as FixedLengthArray, - encrypted_logs_hash: combinedAccumulatedData.encryptedLogsHash.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - 2 - >, - unencrypted_logs_hash: combinedAccumulatedData.unencryptedLogsHash.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - 2 - >, + read_requests: mapTuple(combinedAccumulatedData.readRequests, mapFieldToNoir), + pending_read_requests: mapTuple(combinedAccumulatedData.pendingReadRequests, mapFieldToNoir), + new_commitments: mapTuple(combinedAccumulatedData.newCommitments, mapFieldToNoir), + new_nullifiers: mapTuple(combinedAccumulatedData.newNullifiers, mapFieldToNoir), + nullified_commitments: mapTuple(combinedAccumulatedData.nullifiedCommitments, mapFieldToNoir), + private_call_stack: mapTuple(combinedAccumulatedData.privateCallStack, mapCallRequestToNoir), + public_call_stack: mapTuple(combinedAccumulatedData.publicCallStack, mapCallRequestToNoir), + new_l2_to_l1_msgs: mapTuple(combinedAccumulatedData.newL2ToL1Msgs, mapFieldToNoir), + encrypted_logs_hash: mapTuple(combinedAccumulatedData.encryptedLogsHash, mapFieldToNoir), + unencrypted_logs_hash: mapTuple(combinedAccumulatedData.unencryptedLogsHash, mapFieldToNoir), encrypted_log_preimages_length: mapFieldToNoir(combinedAccumulatedData.encryptedLogPreimagesLength), unencrypted_log_preimages_length: mapFieldToNoir(combinedAccumulatedData.unencryptedLogPreimagesLength), - new_contracts: combinedAccumulatedData.newContracts.map(mapNewContractDataToNoir) as FixedLengthArray< - NewContractDataNoir, - 1 - >, - optionally_revealed_data: combinedAccumulatedData.optionallyRevealedData.map( - mapOptionallyRevealedDataToNoir, - ) as FixedLengthArray, - public_data_update_requests: combinedAccumulatedData.publicDataUpdateRequests.map( + new_contracts: mapTuple(combinedAccumulatedData.newContracts, mapNewContractDataToNoir), + optionally_revealed_data: mapTuple(combinedAccumulatedData.optionallyRevealedData, mapOptionallyRevealedDataToNoir), + public_data_update_requests: mapTuple( + combinedAccumulatedData.publicDataUpdateRequests, mapPublicDataUpdateRequestToNoir, - ) as FixedLengthArray, - public_data_reads: combinedAccumulatedData.publicDataReads.map(mapPublicDataReadToNoir) as FixedLengthArray< - PublicDataReadNoir, - 16 - >, + ), + public_data_reads: mapTuple(combinedAccumulatedData.publicDataReads, mapPublicDataReadToNoir), }; } @@ -961,7 +892,7 @@ export function mapPreviousKernelDataToNoir(previousKernelData: PreviousKernelDa proof: {}, vk: {}, vk_index: mapFieldToNoir(new Fr(previousKernelData.vkIndex)), - vk_path: previousKernelData.vkPath.map(mapFieldToNoir) as FixedLengthArray, + vk_path: mapTuple(previousKernelData.vkPath, mapFieldToNoir), }; } @@ -1034,8 +965,8 @@ export function mapPrivateKernelInputsOrderingToNoir( ): PrivateKernelInputsOrderingNoir { return { previous_kernel: mapPreviousKernelDataToNoir(inputs.previousKernel), - read_commitment_hints: inputs.readCommitmentHints.map(mapFieldToNoir) as FixedLengthArray, - nullifier_commitment_hints: inputs.nullifierCommitmentHints.map(mapFieldToNoir) as FixedLengthArray, + read_commitment_hints: mapTuple(inputs.readCommitmentHints, mapFieldToNoir), + nullifier_commitment_hints: mapTuple(inputs.nullifierCommitmentHints, mapFieldToNoir), }; } @@ -1119,19 +1050,17 @@ export function mapPublicCircuitPublicInputsToNoir( return { call_context: mapCallContextToNoir(publicInputs.callContext), args_hash: mapFieldToNoir(publicInputs.argsHash), - return_values: publicInputs.returnValues.map(mapFieldToNoir) as FixedLengthArray, - contract_storage_update_requests: publicInputs.contractStorageUpdateRequests.map( + return_values: mapTuple(publicInputs.returnValues, mapFieldToNoir), + contract_storage_update_requests: mapTuple( + publicInputs.contractStorageUpdateRequests, mapStorageUpdateRequestToNoir, - ) as FixedLengthArray, - contract_storage_reads: publicInputs.contractStorageReads.map(mapStorageReadToNoir) as FixedLengthArray< - StorageReadNoir, - 16 - >, - public_call_stack_hashes: publicInputs.publicCallStackHashes.map(mapFieldToNoir) as FixedLengthArray, - new_commitments: publicInputs.newCommitments.map(mapFieldToNoir) as FixedLengthArray, - new_nullifiers: publicInputs.newNullifiers.map(mapFieldToNoir) as FixedLengthArray, - new_l2_to_l1_msgs: publicInputs.newL2ToL1Msgs.map(mapFieldToNoir) as FixedLengthArray, - unencrypted_logs_hash: publicInputs.unencryptedLogsHash.map(mapFieldToNoir) as FixedLengthArray, + ), + contract_storage_reads: mapTuple(publicInputs.contractStorageReads, mapStorageReadToNoir), + public_call_stack_hashes: mapTuple(publicInputs.publicCallStackHashes, mapFieldToNoir), + new_commitments: mapTuple(publicInputs.newCommitments, mapFieldToNoir), + new_nullifiers: mapTuple(publicInputs.newNullifiers, mapFieldToNoir), + new_l2_to_l1_msgs: mapTuple(publicInputs.newL2ToL1Msgs, mapFieldToNoir), + unencrypted_logs_hash: mapTuple(publicInputs.unencryptedLogsHash, mapFieldToNoir), unencrypted_log_preimages_length: mapFieldToNoir(publicInputs.unencryptedLogPreimagesLength), block_header: mapBlockHeaderToNoir(publicInputs.blockHeader), @@ -1183,7 +1112,7 @@ export function mapBaseOrMergeRollupPublicInputsToNoir( end_contract_tree_snapshot: mapAppendOnlyTreeSnapshotToNoir(baseOrMergeRollupPublicInputs.endContractTreeSnapshot), start_public_data_tree_root: mapFieldToNoir(baseOrMergeRollupPublicInputs.startPublicDataTreeRoot), end_public_data_tree_root: mapFieldToNoir(baseOrMergeRollupPublicInputs.endPublicDataTreeRoot), - calldata_hash: baseOrMergeRollupPublicInputs.calldataHash.map(mapFieldToNoir) as FixedLengthArray, + calldata_hash: mapTuple(baseOrMergeRollupPublicInputs.calldataHash, mapFieldToNoir), }; } @@ -1209,7 +1138,7 @@ export function mapPublicCallStackItemToNoir(publicCallStackItem: PublicCallStac export function mapPublicCallDataToNoir(publicCall: PublicCallData): PublicCallDataNoir { return { call_stack_item: mapPublicCallStackItemToNoir(publicCall.callStackItem), - public_call_stack: publicCall.publicCallStack.map(mapCallRequestToNoir) as FixedLengthArray, + public_call_stack: mapTuple(publicCall.publicCallStack, mapCallRequestToNoir), proof: {}, portal_contract_address: mapEthAddressToNoir(EthAddress.fromField(publicCall.portalContractAddress)), bytecode_hash: mapFieldToNoir(publicCall.bytecodeHash), @@ -1255,7 +1184,7 @@ export function mapPreviousRollupDataToNoir(previousRollupData: PreviousRollupDa vk_index: mapFieldToNoir(new Fr(previousRollupData.vkIndex)), vk_sibling_path: { leaf_index: mapFieldToNoir(new Fr(previousRollupData.vkSiblingPath.leafIndex)), - sibling_path: previousRollupData.vkSiblingPath.siblingPath.map(mapFieldToNoir) as FixedLengthArray, + sibling_path: mapTuple(previousRollupData.vkSiblingPath.siblingPath, mapFieldToNoir), }, }; } @@ -1302,22 +1231,17 @@ export function mapAppendOnlyTreeSnapshotToNoir(snapshot: AppendOnlyTreeSnapshot */ export function mapRootRollupInputsToNoir(rootRollupInputs: RootRollupInputs): RootRollupInputsNoir { return { - previous_rollup_data: rootRollupInputs.previousRollupData.map(mapPreviousRollupDataToNoir) as FixedLengthArray< - PreviousRollupDataNoir, - 2 - >, - new_l1_to_l2_messages: rootRollupInputs.newL1ToL2Messages.map(mapFieldToNoir) as FixedLengthArray, - new_l1_to_l2_messages_tree_root_sibling_path: rootRollupInputs.newL1ToL2MessagesTreeRootSiblingPath.map( + previous_rollup_data: mapTuple(rootRollupInputs.previousRollupData, mapPreviousRollupDataToNoir), + new_l1_to_l2_messages: mapTuple(rootRollupInputs.newL1ToL2Messages, mapFieldToNoir), + new_l1_to_l2_messages_tree_root_sibling_path: mapTuple( + rootRollupInputs.newL1ToL2MessagesTreeRootSiblingPath, mapFieldToNoir, - ) as FixedLengthArray, + ), start_l1_to_l2_messages_tree_snapshot: mapAppendOnlyTreeSnapshotToNoir( rootRollupInputs.startL1ToL2MessagesTreeSnapshot, ), start_blocks_tree_snapshot: mapAppendOnlyTreeSnapshotToNoir(rootRollupInputs.startBlocksTreeSnapshot), - new_blocks_tree_sibling_path: rootRollupInputs.newBlocksTreeSiblingPath.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - 16 - >, + new_blocks_tree_sibling_path: mapTuple(rootRollupInputs.newBlocksTreeSiblingPath, mapFieldToNoir), }; } @@ -1366,10 +1290,7 @@ export function mapRootRollupPublicInputsFromNoir( */ export function mapMergeRollupInputsToNoir(mergeRollupInputs: MergeRollupInputs): MergeRollupInputsNoir { return { - previous_rollup_data: mergeRollupInputs.previousRollupData.map(mapPreviousRollupDataToNoir) as FixedLengthArray< - PreviousRollupDataNoir, - 2 - >, + previous_rollup_data: mapTuple(mergeRollupInputs.previousRollupData, mapPreviousRollupDataToNoir), }; } @@ -1398,10 +1319,7 @@ export function mapNullifierMembershipWitnessToNoir( ): NullifierMembershipWitnessNoir { return { leaf_index: membershipWitness.leafIndex.toString(), - sibling_path: membershipWitness.siblingPath.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof NULLIFIER_TREE_HEIGHT - >, + sibling_path: mapTuple(membershipWitness.siblingPath, mapFieldToNoir), }; } @@ -1415,10 +1333,7 @@ export function mapBlocksTreeRootMembershipWitnessToNoir( ): BlocksTreeRootMembershipWitnessNoir { return { leaf_index: membershipWitness.leafIndex.toString(), - sibling_path: membershipWitness.siblingPath.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - typeof BLOCKS_TREE_HEIGHT - >, + sibling_path: mapTuple(membershipWitness.siblingPath, mapFieldToNoir), }; } @@ -1429,43 +1344,34 @@ export function mapBlocksTreeRootMembershipWitnessToNoir( */ export function mapBaseRollupInputsToNoir(inputs: BaseRollupInputs): BaseRollupInputsNoir { return { - kernel_data: inputs.kernelData.map(mapPreviousKernelDataToNoir) as FixedLengthArray, + kernel_data: mapTuple(inputs.kernelData, mapPreviousKernelDataToNoir), start_note_hash_tree_snapshot: mapAppendOnlyTreeSnapshotToNoir(inputs.startNoteHashTreeSnapshot), start_nullifier_tree_snapshot: mapAppendOnlyTreeSnapshotToNoir(inputs.startNullifierTreeSnapshot), start_contract_tree_snapshot: mapAppendOnlyTreeSnapshotToNoir(inputs.startContractTreeSnapshot), start_public_data_tree_root: mapFieldToNoir(inputs.startPublicDataTreeRoot), start_blocks_tree_snapshot: mapAppendOnlyTreeSnapshotToNoir(inputs.startBlocksTreeSnapshot), - sorted_new_nullifiers: inputs.sortedNewNullifiers.map(mapFieldToNoir) as FixedLengthArray, - sorted_new_nullifiers_indexes: inputs.sortednewNullifiersIndexes.map(mapNumberToNoir) as FixedLengthArray< - NoirField, - 128 - >, - low_nullifier_leaf_preimages: inputs.lowNullifierLeafPreimages.map( - mapNullifierLeafPreimageToNoir, - ) as FixedLengthArray, - low_nullifier_membership_witness: inputs.lowNullifierMembershipWitness.map( + sorted_new_nullifiers: mapTuple(inputs.sortedNewNullifiers, mapFieldToNoir), + sorted_new_nullifiers_indexes: mapTuple(inputs.sortednewNullifiersIndexes, mapNumberToNoir), + low_nullifier_leaf_preimages: mapTuple(inputs.lowNullifierLeafPreimages, mapNullifierLeafPreimageToNoir), + low_nullifier_membership_witness: mapTuple( + inputs.lowNullifierMembershipWitness, mapNullifierMembershipWitnessToNoir, - ) as FixedLengthArray, - new_commitments_subtree_sibling_path: inputs.newCommitmentsSubtreeSiblingPath.map( - mapFieldToNoir, - ) as FixedLengthArray, - new_nullifiers_subtree_sibling_path: inputs.newNullifiersSubtreeSiblingPath.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - 13 - >, - new_contracts_subtree_sibling_path: inputs.newContractsSubtreeSiblingPath.map(mapFieldToNoir) as FixedLengthArray< - NoirField, - 15 - >, - new_public_data_update_requests_sibling_paths: inputs.newPublicDataUpdateRequestsSiblingPaths.map(siblingPath => - siblingPath.map(mapFieldToNoir), - ) as FixedLengthArray, 32>, - new_public_data_reads_sibling_paths: inputs.newPublicDataReadsSiblingPaths.map(siblingPath => - siblingPath.map(mapFieldToNoir), - ) as FixedLengthArray, 32>, - blocks_tree_root_membership_witnesses: inputs.blocksTreeRootMembershipWitnesses.map( + ), + new_commitments_subtree_sibling_path: mapTuple(inputs.newCommitmentsSubtreeSiblingPath, mapFieldToNoir), + new_nullifiers_subtree_sibling_path: mapTuple(inputs.newNullifiersSubtreeSiblingPath, mapFieldToNoir), + new_contracts_subtree_sibling_path: mapTuple(inputs.newContractsSubtreeSiblingPath, mapFieldToNoir), + new_public_data_update_requests_sibling_paths: mapTuple( + inputs.newPublicDataUpdateRequestsSiblingPaths, + (siblingPath: Tuple) => mapTuple(siblingPath, mapFieldToNoir), + ), + new_public_data_reads_sibling_paths: mapTuple( + inputs.newPublicDataReadsSiblingPaths, + (siblingPath: Tuple) => mapTuple(siblingPath, mapFieldToNoir), + ), + blocks_tree_root_membership_witnesses: mapTuple( + inputs.blocksTreeRootMembershipWitnesses, mapBlocksTreeRootMembershipWitnessToNoir, - ) as FixedLengthArray, + ), constants: mapConstantRollupDataToNoir(inputs.constants), }; } From 18a8b5b5a40c633b0ce5995138b022a36df729ae Mon Sep 17 00:00:00 2001 From: Santiago Palladino Date: Fri, 1 Dec 2023 20:11:32 -0300 Subject: [PATCH 13/13] Fix me being an idiot --- yarn-project/foundation/src/testing/test_data.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yarn-project/foundation/src/testing/test_data.ts b/yarn-project/foundation/src/testing/test_data.ts index f6ceaaa371f..976701e3489 100644 --- a/yarn-project/foundation/src/testing/test_data.ts +++ b/yarn-project/foundation/src/testing/test_data.ts @@ -2,7 +2,7 @@ const testData: { [key: string]: { toBuffer(): Buffer }[] } = {}; /** Returns whether test data generation is enabled */ export function isGenerateTestDataEnabled() { - return process.env.AZTEC_GENERATE_TEST_DATA === '1' || typeof expect !== 'undefined'; + return process.env.AZTEC_GENERATE_TEST_DATA === '1' && typeof expect !== 'undefined'; } /** Pushes test data with the given name, only if test data generation is enabled. */