You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-`aux_data` is the data which is appended to `pre_deploy_data_section` on `RETURNCONTRACT` instruction [see New Behavior](#new-behavior).
86
-
-`static_aux_data` is a subrange of `aux_data`, which size is known before `RETURNCONTRACT` and equals `pre_deploy_data_size - len(pre_deploy_data_section)`.
85
+
-`aux_data` is the data which is appended to `pre_deploy_data_section` on `RETURNCODE` instruction [see New Behavior](#new-behavior).
86
+
-`static_aux_data` is a subrange of `aux_data`, which size is known before `RETURNCODE` and equals `pre_deploy_data_size - len(pre_deploy_data_section)`.
87
87
-`dynamic_aux_data` is the remainder of `aux_data`.
88
88
89
89
`data_size` in the deployed container header is also updated to be equal `len(data_section)`.
@@ -242,8 +242,8 @@ The following instructions are introduced in EOF code:
242
242
- behavior on `accessed_addresses` and address colission is same as `CREATE2` (rules for `CREATE2` from [EIP-684](https://eips.ethereum.org/EIPS/eip-684) and [EIP-2929](https://eips.ethereum.org/EIPS/eip-2929) apply to `EOFCREATE`)
243
243
- an unsuccesful execution of initcode results in pushing `0` onto the stack
244
244
- can populate returndata if execution `REVERT`ed
245
-
- a successful execution ends with initcode executing `RETURNCONTRACT{deploy_container_index}(aux_data_offset, aux_data_size)` instruction (see below). After that:
246
-
- load deploy-contract from EOF subcontainer at `deploy_container_index` in the container from which `RETURNCONTRACT` is executed
245
+
- a successful execution ends with initcode executing `RETURNCODE{deploy_container_index}(aux_data_offset, aux_data_size)` instruction (see below). After that:
246
+
- load deploy-contract from EOF subcontainer at `deploy_container_index` in the container from which `RETURNCODE` is executed
247
247
- concatenate data section with `(aux_data_offset, aux_data_offset + aux_data_size)` memory segment and update data size in the header
248
248
- let `deployed_code_size` be updated deploy container size
249
249
- if `deployed_code_size > MAX_CODE_SIZE` instruction exceptionally aborts
@@ -264,7 +264,7 @@ The following instructions are introduced in EOF code:
264
264
- in addition to this, checks if the initcode container has its `len(data_section)` equal to `data_size`, i.e. data section content is exactly as the size declared in the header (see [Data section lifecycle](#data-section-lifecycle))
265
265
- fails (returns 0 on the stack) if any of those was invalid
266
266
- caller’s nonce is not updated and gas for initcode execution is not consumed. Only `TXCREATE` constant gas was consumed
- pops two values from the stack: `aux_data_offset`, `aux_data_size` referring to memory section that will be appended to deployed container's data
270
270
- cost 0 gas + possible memory expansion for aux data
@@ -337,14 +337,14 @@ The following instructions are introduced in EOF code:
337
337
-`EOFCREATE``initcontainer_index` must be less than `num_container_sections`
338
338
-`EOFCREATE` the subcontainer pointed to by `initcontainer_index` must have its `len(data_section)` equal `data_size`, i.e. data section content is exactly as the size declared in the header (see [Data section lifecycle](#data-section-lifecycle))
339
339
-`EOFCREATE` the subcontainer pointed to by `initcontainer_index`*must not* contain either a `RETURN` or `STOP` instruction.
340
-
-`RETURNCONTRACT``deploy_container_index` must be less than `num_container_sections`
341
-
-`RETURNCONTRACT` the subcontainer pointed to `deploy_container_index`*must not* contain a `RETURNCONTRACT` instruction.
340
+
-`RETURNCODE``deploy_container_index` must be less than `num_container_sections`
341
+
-`RETURNCODE` the subcontainer pointed to `deploy_container_index`*must not* contain a `RETURNCODE` instruction.
342
342
-`DATALOADN`'s `immediate + 32` must be within `pre_deploy_data_size` (see [Data Section Lifecycle](#data-section-lifecycle))
343
343
- the part of the data section which exceeds these bounds (the `dynamic_aux_data` portion) needs to be accessed using `DATALOAD` or `DATACOPY`
344
344
- no unreachable code sections are allowed, i.e. every code section can be reached from the 0th code section with a series of CALLF / JUMPF instructions, and section 0 is implicitly reachable.
345
-
- it is an error for a container to contain both `RETURNCONTRACT` and either of `RETURN` or `STOP`.
345
+
- it is an error for a container to contain both `RETURNCODE` and either of `RETURN` or `STOP`.
346
346
- it is an error for a subcontainer to never be referenced in its parent container
347
-
- it is an error for a given subcontainer to be referenced by both `RETURNCONTRACT` and `EOFCREATE`
347
+
- it is an error for a given subcontainer to be referenced by both `RETURNCODE` and `EOFCREATE`
348
348
349
349
## Stack Validation
350
350
@@ -357,7 +357,7 @@ The following instructions are introduced in EOF code:
357
357
-*Forward jump* refers to any of `RJUMP`/`RJUMPI`/`RJUMPV` instruction with relative offset greater than or equal to 0. *Backwards jump* refers to any of `RJUMP`/`RJUMPI`/`RJUMPV` instruction with relative offset less than 0, including jumps to the same jump instruction (e.g. `RJUMP(-3)`)
- For each instruction in the code the operand stack height bounds are recorded as `stack_height_min` and `stack_height_max`. Instructions are scanned in a single linear pass over the code.
362
362
- first instruction has `stack_height_min = stack_height_max = types[current_section_index].inputs`.
0 commit comments