forked from Consensys/linea-specification
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathintro.tex
15 lines (13 loc) · 1.47 KB
/
intro.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
The \romMod{} module contains \emph{nonempty} bytecodes (i.e. words $\in\mathbb{B}^*$) of contracts used within a conflation of blocks (and thus all transactions contained therein) as well as some associated metadata.
Its main role in the overall design is to provide the \hubMod{} module with the correct sequence of instructions.
It furthermore is responsible for assembling the \inst{PUSH}-values and for tagging (in)valid jump destinations as required by \textsc{jump destination analysis}.
Most of the arithmetization below focuses on building the \romMod{} module as a sequence of padded byte codes and of extracting the correct push values from it (i.e. the $X$-byte long arguments of actual \inst{PUSH\_X} instructions).
There are three kinds of accesses to bytecode that the \romMod{} module deals with, with contract deployment being subdivided into 1 or 2 phases (since deployments may fail):
\begin{enumerate}
\item loading the full bytecode of an already deployed smart contract to \inst{CALL} it or to \inst{EXTCODECOPY} from it (or both);
\item deploying a smart contract through a deployment transaction or an (unexceptional, unaborted and no failure condition raising) \inst{CREATE(2)} instruction:
\begin{enumerate}
\item loading the initialization code into \romMod{};
\item and for (temporarily) successful deployments loading the bytecode that will be deployed at the relevant address into \romMod{}.
\end{enumerate}
\end{enumerate}