perf: replace StringBuilder with ValueListBuilder<char>#1545
Merged
belav merged 1 commit intobelav:mainfrom Aug 3, 2025
Merged
perf: replace StringBuilder with ValueListBuilder<char>#1545belav merged 1 commit intobelav:mainfrom
StringBuilder with ValueListBuilder<char>#1545belav merged 1 commit intobelav:mainfrom
Conversation
eeaf247 to
9e9ad83
Compare
3ea9bb4 to
b7586f4
Compare
belav
approved these changes
Jul 18, 2025
Owner
belav
left a comment
There was a problem hiding this comment.
Did you figure out why your old benchmarks showed this as being slightly slower?
Contributor
Author
|
In retrospect I think I was being overly paranoid. 😓 This is a net positive for memory usage with a negligible improvement to speed. The benchmarks naturally vary a little |
ade98c7 to
c184562
Compare
c184562 to
32163c5
Compare
belav
approved these changes
Aug 3, 2025
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.
StringBuilderwithValueListBuilder<char>SkipLocalsInitto avoid the cost to zerostackalloc char[]Benchmarks
I have no idea why, all the new changes I make are slower in the benchmarks, even when they should be a straight upgrade 🤔
I'm running into this issue a lot with #1542
Before
After