Repository navigation
Conversation
Contributor
|
Member
Author
|
@djolertrk @cameel would be curious what you think of this approach to solving #291 |
This branch has not been deployed
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.
Implements #291.
This adds a region with
"location": "virtual"for values that no EVM data location stores, e.g. a variable the optimizer removed. The pointer schema's dispatch does not change: a virtual region is just another region, and dereferencing still yields regions only.Every region is base fields plus one addressing scheme. Virtual regions use a new third scheme, ethdebug/format/pointer/scheme/fragment: a width-bearing
expressionsupplies the byte space (the expression's value), and optionaloffset(default0) andlength(default: to the end of the value) address into it. A fragment outside the value's bytes is invalid. The expression is evaluated against the same machine state as the pointer's other regions and may refer only to regions before it. Lookups follow the region's fields, so.offsetand.lengthwork and.slotdoes not;~readgives the fragment's bytes.The reference implementation evaluates the expression while it makes the region concrete, keeps the bytes on the concrete region, and fills in the default
offsetandlength;readreturns the fragment. A new integration case readsa + 1and the first 4 bytes ofkeccak256(a)from a storage variable over a solc trace.Stacked on #408.