-
Notifications
You must be signed in to change notification settings - Fork 8
use IO::Buffer #2
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
Open
kazuho
wants to merge
18
commits into
main
Choose a base branch
from
kazuho/io-buffer
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
80fcd3f
switch to IO::Buffer
kazuho e1bd5e4
delay dup
kazuho a6b38a8
*_from_tuple can be slow
kazuho 7dca4c3
use IO::Buffer#for to generate keys, as suggested by @eregon
kazuho ddd08f0
fix overflow error as well as optimizing adjustments
kazuho d878fa5
Merge branch 'main' into kazuho/io-buffer
kazuho 86cfab7
no need to dup
kazuho 2927025
Merge branch 'main' into kazuho/io-buffer
kazuho cc41d29
Merge branch 'main' into kazuho/io-buffer
kazuho 1b3f739
no default values, move handling of odd-length out of `IP.sum16` as i…
kazuho 70e74bc
Merge branch 'main' into kazuho/io-buffer
kazuho 5380c41
Merge branch 'main' into kazuho/io-buffer
kazuho 99e3878
Merge branch 'main' into kazuho/io-buffer
kazuho 4954481
`packet.tuple` is IO::Buffer
kazuho 86abb0f
declaration should not allow parameter omission
kazuho 2072059
Merge branch 'main' into kazuho/io-buffer
kazuho 9ec5674
Merge branch 'main' into kazuho/io-buffer
kazuho 53fe71e
Merge branch 'main' into kazuho/io-buffer
kazuho File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.
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.
It's neat idea, I didn't think about it. Maybe we can do the similar:
At the end, the buffer would be transferred to string zero copy.
Uh oh!
There was an error while loading. Please reload this page.
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.
That interface SGTM (though I wonder if there should be a static function as part of String that generates a fixed-length, zero-filled bytes). I'm all in to optimizations that reduce the conversion cost bet. the two types.
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.
That seems a nice addition, and it's easy to support without extra copying on TruffleRuby, unlike the current usage here (would need one copy to go from Rope to byte[] internally).