-
Notifications
You must be signed in to change notification settings - Fork 20.3k
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
rlp: improve decoder stream implementation #22858
Merged
Merged
Commits on May 11, 2021
-
This removes a lot unused padding space in Stream by reordering the fields. The size of Stream changes from 120 bytes to 88 bytes. Stream instances are internally cached and reused using sync.Pool, so this change does not improve performance at all. However, I still think it's worth to apply this because the previous definition was so wasteful.
Configuration menu - View commit details
-
Copy full SHA for 4ead400 - Browse repository at this point
Copy the full SHA 4ead400View commit details -
Configuration menu - View commit details
-
Copy full SHA for b5905ea - Browse repository at this point
Copy the full SHA b5905eaView commit details -
Configuration menu - View commit details
-
Copy full SHA for 7b3189f - Browse repository at this point
Copy the full SHA 7b3189fView commit details -
The list stack kept track of the size of the current list context as well as the current offset into it. The size had to be stored in the stack in order to subtract it from the remaining bytes of any enclosing list in ListEnd. It seems that this can be implemented in a simpler way: just subtract the size from the enclosing list context in List instead.
Configuration menu - View commit details
-
Copy full SHA for 9e55e9a - Browse repository at this point
Copy the full SHA 9e55e9aView commit details -
Configuration menu - View commit details
-
Copy full SHA for acda970 - Browse repository at this point
Copy the full SHA acda970View commit details -
Configuration menu - View commit details
-
Copy full SHA for 9759ad9 - Browse repository at this point
Copy the full SHA 9759ad9View commit details -
Configuration menu - View commit details
-
Copy full SHA for dea3923 - Browse repository at this point
Copy the full SHA dea3923View commit details -
Configuration menu - View commit details
-
Copy full SHA for 02b01f9 - Browse repository at this point
Copy the full SHA 02b01f9View commit details -
Configuration menu - View commit details
-
Copy full SHA for b279921 - Browse repository at this point
Copy the full SHA b279921View commit details
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.