-
Notifications
You must be signed in to change notification settings - Fork 234
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: evaluate expressions in constant gen (#6813)
Closes #6808.
- Loading branch information
Showing
4 changed files
with
170 additions
and
300 deletions.
There are no files selected for viewing
76 changes: 31 additions & 45 deletions
76
barretenberg/cpp/src/barretenberg/vm/avm_trace/aztec_constants.hpp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1,34 @@ | ||
// GENERATED FILE - DO NOT EDIT, RUN yarn remake-constants in circuits.js | ||
#pragma once | ||
|
||
#include <cstddef> | ||
|
||
const size_t MAX_NEW_NOTE_HASHES_PER_CALL = 16; | ||
const size_t MAX_NEW_NULLIFIERS_PER_CALL = 16; | ||
const size_t MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL = 16; | ||
const size_t MAX_NEW_L2_TO_L1_MSGS_PER_CALL = 2; | ||
const size_t MAX_PUBLIC_DATA_UPDATE_REQUESTS_PER_CALL = 32; | ||
const size_t MAX_PUBLIC_DATA_READS_PER_CALL = 16; | ||
const size_t MAX_NOTE_HASH_READ_REQUESTS_PER_CALL = 32; | ||
const size_t MAX_NULLIFIER_READ_REQUESTS_PER_CALL = 32; | ||
const size_t MAX_NULLIFIER_NON_EXISTENT_READ_REQUESTS_PER_CALL = 32; | ||
const size_t MAX_L1_TO_L2_MSG_READ_REQUESTS_PER_CALL = 16; | ||
const size_t MAX_UNENCRYPTED_LOGS_PER_CALL = 4; | ||
const size_t AZTEC_ADDRESS_LENGTH = 1; | ||
const size_t GAS_FEES_LENGTH = 2; | ||
const size_t GAS_LENGTH = 2; | ||
const size_t CALL_CONTEXT_LENGTH = 6; | ||
const size_t CONTENT_COMMITMENT_LENGTH = 4; | ||
const size_t CONTRACT_STORAGE_READ_LENGTH = 2; | ||
const size_t CONTRACT_STORAGE_UPDATE_REQUEST_LENGTH = 3; | ||
const size_t GLOBAL_VARIABLES_LENGTH = 6 + GAS_FEES_LENGTH; | ||
const size_t APPEND_ONLY_TREE_SNAPSHOT_LENGTH = 2; | ||
const size_t L2_TO_L1_MESSAGE_LENGTH = 3; | ||
const size_t PARTIAL_STATE_REFERENCE_LENGTH = 6; | ||
const size_t READ_REQUEST_LENGTH = 2; | ||
const size_t LOG_HASH_LENGTH = 3; | ||
const size_t NOTE_HASH_LENGTH = 2; | ||
const size_t NULLIFIER_LENGTH = 3; | ||
const size_t STATE_REFERENCE_LENGTH = APPEND_ONLY_TREE_SNAPSHOT_LENGTH + PARTIAL_STATE_REFERENCE_LENGTH; | ||
const size_t TOTAL_FEES_LENGTH = 1; | ||
const size_t HEADER_LENGTH = APPEND_ONLY_TREE_SNAPSHOT_LENGTH + CONTENT_COMMITMENT_LENGTH + STATE_REFERENCE_LENGTH + | ||
GLOBAL_VARIABLES_LENGTH + TOTAL_FEES_LENGTH; | ||
const size_t PUBLIC_CIRCUIT_PUBLIC_INPUTS_LENGTH = | ||
CALL_CONTEXT_LENGTH + /*argsHash + returnsHash*/ 2 + (READ_REQUEST_LENGTH * MAX_NOTE_HASH_READ_REQUESTS_PER_CALL) + | ||
(READ_REQUEST_LENGTH * MAX_NULLIFIER_READ_REQUESTS_PER_CALL) + | ||
(READ_REQUEST_LENGTH * MAX_NULLIFIER_NON_EXISTENT_READ_REQUESTS_PER_CALL) + | ||
(READ_REQUEST_LENGTH * MAX_L1_TO_L2_MSG_READ_REQUESTS_PER_CALL) + | ||
(CONTRACT_STORAGE_UPDATE_REQUEST_LENGTH * MAX_PUBLIC_DATA_UPDATE_REQUESTS_PER_CALL) + | ||
(CONTRACT_STORAGE_READ_LENGTH * MAX_PUBLIC_DATA_READS_PER_CALL) + MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL + | ||
(NOTE_HASH_LENGTH * MAX_NEW_NOTE_HASHES_PER_CALL) + (NULLIFIER_LENGTH * MAX_NEW_NULLIFIERS_PER_CALL) + | ||
(L2_TO_L1_MESSAGE_LENGTH * MAX_NEW_L2_TO_L1_MSGS_PER_CALL) + 2 + (LOG_HASH_LENGTH * MAX_UNENCRYPTED_LOGS_PER_CALL) + | ||
HEADER_LENGTH + GLOBAL_VARIABLES_LENGTH + AZTEC_ADDRESS_LENGTH + /* revert_code */ 1 + 2 * GAS_LENGTH + | ||
/* transaction_fee */ 1; | ||
const size_t PUBLIC_CONTEXT_INPUTS_LENGTH = | ||
CALL_CONTEXT_LENGTH + HEADER_LENGTH + GLOBAL_VARIABLES_LENGTH + GAS_LENGTH + 2; | ||
#define MAX_NEW_NOTE_HASHES_PER_CALL 16 | ||
#define MAX_NEW_NULLIFIERS_PER_CALL 16 | ||
#define MAX_PUBLIC_CALL_STACK_LENGTH_PER_CALL 16 | ||
#define MAX_NEW_L2_TO_L1_MSGS_PER_CALL 2 | ||
#define MAX_PUBLIC_DATA_UPDATE_REQUESTS_PER_CALL 32 | ||
#define MAX_PUBLIC_DATA_READS_PER_CALL 16 | ||
#define MAX_NOTE_HASH_READ_REQUESTS_PER_CALL 32 | ||
#define MAX_NULLIFIER_READ_REQUESTS_PER_CALL 32 | ||
#define MAX_NULLIFIER_NON_EXISTENT_READ_REQUESTS_PER_CALL 32 | ||
#define MAX_L1_TO_L2_MSG_READ_REQUESTS_PER_CALL 16 | ||
#define MAX_UNENCRYPTED_LOGS_PER_CALL 4 | ||
#define AZTEC_ADDRESS_LENGTH 1 | ||
#define GAS_FEES_LENGTH 2 | ||
#define GAS_LENGTH 2 | ||
#define CALL_CONTEXT_LENGTH 6 | ||
#define CONTENT_COMMITMENT_LENGTH 4 | ||
#define CONTRACT_STORAGE_READ_LENGTH 2 | ||
#define CONTRACT_STORAGE_UPDATE_REQUEST_LENGTH 3 | ||
#define GLOBAL_VARIABLES_LENGTH 8 | ||
#define APPEND_ONLY_TREE_SNAPSHOT_LENGTH 2 | ||
#define L2_TO_L1_MESSAGE_LENGTH 3 | ||
#define PARTIAL_STATE_REFERENCE_LENGTH 6 | ||
#define READ_REQUEST_LENGTH 2 | ||
#define LOG_HASH_LENGTH 3 | ||
#define NOTE_HASH_LENGTH 2 | ||
#define NULLIFIER_LENGTH 3 | ||
#define STATE_REFERENCE_LENGTH 8 | ||
#define TOTAL_FEES_LENGTH 1 | ||
#define HEADER_LENGTH 23 | ||
#define PUBLIC_CIRCUIT_PUBLIC_INPUTS_LENGTH 514 | ||
#define PUBLIC_CONTEXT_INPUTS_LENGTH 41 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.