[PREVIEW] EIP-8141 canonical paymaster — Stage 2 bytecode/hash/gas - #5
Draft
Marchhill wants to merge 6 commits into
Draft
[PREVIEW] EIP-8141 canonical paymaster — Stage 2 bytecode/hash/gas#5Marchhill wants to merge 6 commits into
Marchhill wants to merge 6 commits into
Conversation
…measured gas Insert the assembled 355-byte runtime bytecode and its per-fork keccak256 code hash into the canonical paymaster section, replace the ~2,150 gas estimate with the measured validation-path cost, and add the reference artifacts asset file.
Present the reference contract as annotated EVM assembly (mnemonics, labels, per-block comments) alongside the compiled bytecode and code hash, matching the house style of the system-contract EIPs. The listing assembles byte-for-byte to the pinned runtime bytecode and hash.
…prose Describe the validation-path cost structurally (dispatch, three SIGPARAM reads, memory-only APPROVE, one cold SLOAD) rather than quoting a fork-specific gas figure, since the deployment fork is undetermined. Tighten the assets pointer and reproducibility note.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Private preview — NOT for upstream
This is a private preview inside Marc's own fork of the Stage-2 additions that would eventually go into
ethereum/EIPsPR ethereum#12012 ("specify the canonical paymaster implementation"). Nothing here is posted to, or intended for, the upstream PR yet. The base branch (stage2-preview-base) is the exact current ethereum#12012 content, so this diff shows only the Stage-2 delta.What this adds to
EIPS/eip-8141.mdkeccak256code hash0xda42f0d11838c4c0c3129b8b8e93e9718127ad6b315e517e1088125707c4d45cinto the canonical paymaster section (replacing the "will be added to this section" placeholders).~2,150 gasestimate with the measured validation-path cost.assets/eip-8141/canonical-paymaster.mdwith the bytecode + hash, per the EIP assets convention.The bytecode and hash are reproducible from the checked-in reference assembler (
paymaster_asm.py, two-pass label resolution, self-contained keccak-256) — running it re-emits both values byte-for-byte.Gas number provenance. The new wording asserts ~3,100 gas / measured 3,110 for the
payframe. That figure was measured on Nethermind'seip8141-frame-txs-devnet7fork, which carries the EIP-8037/8038 state-gas repricing (coldSLOADraised above the EIP-2929 2,100). Update EIP-8141: specify the canonical paymaster implementation ethereum/EIPs#12012 may be normative against a different cost schedule, in which case this number is misleading. Confirm with the PR author which cost schedule the spec is normative against before adopting this figure.Pseudocode block. The draft's §5 alignment (change
!= SECP256K1→!= ARBITRARY, andrequire CALLER == SLOAD(0)→ caller-OR-signer form) was checked against the live text: the published pseudocode already matches the intended final form (it already reads== ARBITRARY/if CALLER == SLOAD(0): return truewith the signature fallback). So no pseudocode change was made — please confirm that is the expected state.Anchor note
The draft assumed a "(… listed in the assets file)" parenthetical; the live text instead read "(normative; the assembled bytecode and its code hash will be added to this section)". The edit was adapted accordingly: the parenthetical is now
(normative), and the bytecode/hash are listed in-section (mirroring the expiry-verifier convention) plus pointed at the new assets file.