Skip to content

Commit

Permalink
docs(yellowpaper): avm tree-access operations (#4552)
Browse files Browse the repository at this point in the history
  • Loading branch information
dbanks12 authored and AztecBot committed Feb 14, 2024
1 parent 4e529dd commit c1b60d1
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 13 deletions.
16 changes: 10 additions & 6 deletions cpp/src/barretenberg/vm/avm_trace/AvmMini_opcode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,16 +66,18 @@ const std::unordered_map<OpCode, size_t> Bytecode::OPERANDS_NUM = {
//{ OpCode::CMOV, },

//// World State
//{ OpCode::BLOCKHEADERBYNUMBER, },
//{ OpCode::SLOAD, }, // Public Storage
//{ OpCode::SSTORE, }, // Public Storage
//{ OpCode::READL1TOL2MSG, }, // Messages
//{ OpCode::SENDL2TOL1MSG, }, // Messages
//{ OpCode::NOTEHASHEXISTS, }, // Notes & Nullifiers
//{ OpCode::EMITNOTEHASH, }, // Notes & Nullifiers
//{ OpCode::NULLIFIEREXISTS, }, // Notes & Nullifiers
//{ OpCode::EMITNULLIFIER, }, // Notes & Nullifiers
//{ OpCode::READL1TOL2MSG, }, // Messages
//{ OpCode::HEADERMEMBER, },

//// Accrued Substate
//{ OpCode::EMITUNENCRYPTEDLOG, },
//{ OpCode::SENDL2TOL1MSG, },

//// Control Flow - Contract Calls
//{ OpCode::CALL, },
Expand Down Expand Up @@ -135,14 +137,16 @@ bool Bytecode::has_in_tag(OpCode const op_code)
case OpCode::INTERNALRETURN:
case OpCode::MOV:
case OpCode::CMOV:
case OpCode::BLOCKHEADERBYNUMBER:
case OpCode::SLOAD:
case OpCode::SSTORE:
case OpCode::READL1TOL2MSG:
case OpCode::SENDL2TOL1MSG:
case OpCode::NOTEHASHEXISTS:
case OpCode::EMITNOTEHASH:
case OpCode::NULLIFIEREXISTS:
case OpCode::EMITNULLIFIER:
case OpCode::READL1TOL2MSG:
case OpCode::HEADERMEMBER:
case OpCode::EMITUNENCRYPTEDLOG:
case OpCode::SENDL2TOL1MSG:
case OpCode::CALL:
case OpCode::STATICCALL:
case OpCode::RETURN:
Expand Down
16 changes: 9 additions & 7 deletions cpp/src/barretenberg/vm/avm_trace/AvmMini_opcode.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -74,16 +74,18 @@ enum class OpCode : uint8_t {
CMOV,

// World State
BLOCKHEADERBYNUMBER,
SLOAD, // Public Storage
SSTORE, // Public Storage
READL1TOL2MSG, // Messages
SENDL2TOL1MSG, // Messages
EMITNOTEHASH, // Notes & Nullifiers
EMITNULLIFIER, // Notes & Nullifiers
SLOAD, // Public Storage
SSTORE, // Public Storage
NOTEHASHEXISTS, // Notes & Nullifiers
EMITNOTEHASH, // Notes & Nullifiers
NULLIFIEREXISTS, // Notes & Nullifiers
EMITNULLIFIER, // Notes & Nullifiers
READL1TOL2MSG, // Messages
HEADERMEMBER, // Archive tree & Headers

// Accrued Substate
EMITUNENCRYPTEDLOG,
SENDL2TOL1MSG, // Messages

// Control Flow - Contract Calls
CALL,
Expand Down

0 comments on commit c1b60d1

Please sign in to comment.