Skip to content

fix(rpc): capture missing vmTrace opcode effects - #2885

Draft
banteg wants to merge 1 commit into
erigontech:masterfrom
banteg:fix/vmtrace-cancun-opcodes
Draft

banteg wants to merge 1 commit into
erigontech:masterfrom
banteg:fix/vmtrace-cancun-opcodes

Conversation

@banteg

@banteg banteg commented Sep 13, 2026

Copy link
Copy Markdown

The VM tracer omits the stack results of PUSH0, TLOAD, BLOBHASH, and BLOBBASEFEE, and omits the memory ranges for MCOPY and EXTCODECOPY. This prevents consumers from reconstructing stack and memory from the compressed trace.

Extend the existing opcode tables and their exhaustive opcode tests. EXTCODECOPY reads its destination and length below the address operand; MCOPY uses the same destination/length positions as the other three-operand copy instructions. The Cancun constants come from the pinned evmone headers because the pinned EVMC opcode enum does not define them.

Validation: make fmt lint passes. A focused native C++20 harness compiled the unchanged production helper functions against the pinned evmone/EVMC/intx headers: all six added cases failed on the baseline and pass after the fix. The full RPC test binary has not been built locally; leaving this in draft until that validation is available.

Upstream CI: lint passes. The CircleCI Linux build jobs fail before compilation because the project cannot use the configured 2xlarge machine resource class (resource-class-not-in-plan); this is not a test result.

Discovered during the evm-trace reconstruction investigation, which compares compressed Parity VM traces expanded into full traces against other tracing methods. The client-side regressions here isolate the affected trace-generation behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant