Skip to content

perf: replace ToString with AsRef - #1415

Merged
meskill merged 1 commit into
mainfrom
meskill-2026-08-22-perf--mqq
Aug 22, 2026
Merged

perf: replace ToString with AsRef#1415
meskill merged 1 commit into
mainfrom
meskill-2026-08-22-perf--mqq

Conversation

@meskill

@meskill meskill commented Aug 22, 2026

Copy link
Copy Markdown
Contributor

Avoid allocations when possible for different net messages by avoiding ToString trait and using AsRef.

before -> after
image

before
image

after
image

I have to come up with very specific shape of benchmark sql to see the good performance boost, otherwise it was not hurting performance anyway in most cases, but better to overprovision.

@codecov

codecov Bot commented Aug 22, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@levkk levkk left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome

@meskill
meskill merged commit b460126 into main Aug 22, 2026
29 checks passed
@meskill
meskill deleted the meskill-2026-08-22-perf--mqq branch August 22, 2026 15:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants