-
Notifications
You must be signed in to change notification settings - Fork 435
Refactor headers and improve performance #4494
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
Merged
Merged
Conversation
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
CodSpeed Performance ReportMerging #4494 will improve performances by ×2.2Comparing Summary
Benchmarks breakdown
|
36784fb
to
7802b6c
Compare
Can you move to the new file on a different PR? It's not possible to see what has changed when you move the whole implementation to a new file. |
The move to a different file is in a different commit already. That said, pretty much the entire impl is changed through these series of commits. |
anonrig
reviewed
Jul 11, 2025
anonrig
approved these changes
Jul 11, 2025
Remove the per-string accounting and instead account per header entry.
When header names are set from our own code, and we know they are valid, we can skip validation. If the header name is already known to the Headers class we can also skip allocation.
When we know we are holding the isolate lock, we can avoid the overhead of the deferred adjustment mechanism and just adjust the isolate external memory directly.
0ab6472
to
5f01fd8
Compare
5f01fd8
to
1ea5b7c
Compare
jasnell
added a commit
that referenced
this pull request
Aug 19, 2025
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.
This is a refactor of the Headers implementation that improves construction benchmark performance.... The revised impl passes all WPT's and other tests and reduces per-header memory usage and memory accounting overhead while we're at it. Offering this as input to #4472