Skip to content

Only store status text if necessary#5470

Merged
jasnell merged 1 commit intomainfrom
jasnell/simplify-http-response-statustext
Nov 6, 2025
Merged

Only store status text if necessary#5470
jasnell merged 1 commit intomainfrom
jasnell/simplify-http-response-statustext

Conversation

@jasnell
Copy link
Collaborator

@jasnell jasnell commented Nov 6, 2025

Eliminate some unnecesssary string copies and allocations when the Response statustext matches the default or is not provided + a couple other smaller drive-bys while in there...

@jasnell jasnell requested review from a team as code owners November 6, 2025 16:20
@codspeed-hq
Copy link

codspeed-hq bot commented Nov 6, 2025

CodSpeed Performance Report

Merging #5470 will improve performances by 10.1%

Comparing jasnell/simplify-http-response-statustext (73ba244) with main (502dead)

Summary

⚡ 1 improvement
✅ 33 untouched
⏩ 9 skipped1

Benchmarks breakdown

Benchmark BASE HEAD Change
nullBodyWithStatus[Response] 10 µs 9.1 µs +10.1%

Footnotes

  1. 9 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

Eliminate some unnecesssary string copies and allocations
when the Response statustext matches the default or is
not provided.
@jasnell jasnell force-pushed the jasnell/simplify-http-response-statustext branch from 506c0e0 to 73ba244 Compare November 6, 2025 17:23
@jasnell jasnell merged commit e75a5ee into main Nov 6, 2025
21 checks passed
@jasnell jasnell deleted the jasnell/simplify-http-response-statustext branch November 6, 2025 18:00
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.

3 participants