-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Have creation transactions run in runtime mode #118
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added some first thoughts which occurred to me during writing this down
|
||
1. intrinsic gas cost rules and limits defined in EIP-3860 for legacy creation transaction apply. The entire `data` of the transaction is used for these calculations | ||
2. Find the split of `data` into `initcontainer` and `calldata`: | ||
1. intrinsic gas cost rules and limits defined in EIP-3860 for legacy creation transaction apply. The entire `data` of the transaction is used for these calculations, as if it were the initcode |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Potential Problem 1: applying initcode-specific rules (eip-3860) to something which is not initcode
|
||
**NOTE** No code is ever set to `tx_address` but storage may be set and receives transaction value. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Potential Problem 2: this smells to me. I even consider adding a magic to the tx_address
keccak256 for good measure. Decided not to, but I don't like this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is commonly discussed thing: should the storage persist in such account. In this context this address is used only once so this is not very practical.
The first version of 7702 actually sets code for the duration of the transaction. I think this may be fine too.
@@ -128,27 +128,21 @@ Code executing within an EOF environment will behave differently than legacy cod | |||
|
|||
#### Creation transactions | |||
|
|||
Creation transactions (tranactions with empty `to`), with `data` containing EOF code (starting with `EF00` magic) are interpreted as having a concatenation of EOF `initcontainer` and `calldata` in the `data` and: | |||
Creation transactions (tranactions with empty `to`), with `data` containing EOF code (starting with `EF00` magic) are interpreted as having a concatenation of an EOF `txcontainer` and `calldata` in the `data` and: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I invented a new name for this. Calling it "an EOF runtime container" seemed somewhat off (?) not sure why
Idea dropped on the EOF impls call (reasons in comments here and #119 also and here: ethereum/pm#1051 (comment) ) |
Taking the liberty to duplicate @shemnon 's feedback on this here for completeness, and also to reply to it:
|
All valid points, I just want to throw in here I'm not sure about the part quoted above - the "sender" address for the top-level frame changes every time (it is But nevertheless, I think the storage (and value!) are problems for this #118 here. |
Formalization of the idea tossed on discord and discussed briefly during the EOF implementers call.
Opening the PR just to assess the fresh idea in writing, does not mean yet we're changing the spec.
Another PR with the version to relax the RETURN/STOP validation instead: #119