-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
opt/bench: fix benchmark regression #138740
Conversation
PR cockroachdb#138641 caused extra allocations for plan gist factories in optimizer benchmarks. These allocations should not be included in benchmark results, so they have been eliminated. Release note: None
|
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.
Reviewed 1 of 1 files at r1, all commit messages.
Reviewable status:complete! 1 of 0 LGTMs obtained (waiting on @michae2)
…der` For our purposes in base64-encoding plan gists, using `bytes.Buffer` in `Encoder` causes fewer allocations, presumably because of a more aggressive growth algorithm. Release note: None
I added a second commit. Will post benchmark results of that commit shortly. |
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.
👍
Reviewed 1 of 1 files at r2, all commit messages.
Reviewable status:complete! 0 of 0 LGTMs obtained (and 1 stale) (waiting on @michae2)
Diff between first and second commit:
|
TFTR! bors r+ |
Build failed (retrying...):
|
bors r+ |
opt/bench: fix benchmark regression
PR #138641 caused extra allocations for plan gist factories in optimizer
benchmarks. These allocations should not be included in benchmark
results, so they have been eliminated.
Release note: None
util/base64: use
bytes.Buffer
instead ofstrings.Builder
inEncoder
For our purposes in base64-encoding plan gists, using
bytes.Buffer
inEncoder
causes fewer allocations, presumably because of a moreaggressive growth algorithm.
Epic: None
Release note: None