Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

MihaZupan
Copy link
Member

We're already caching the encoded bytes for HTTP/3. This extends that to H1 and H2.
I also precomputed things like MustHaveRequestBody to avoid some branches on the hot path.

Instead of trying to get the normalized method on each request, that logic is now in the cold path if encoded bytes aren't available yet.

Save a couple ns per request, and 8 bytes off of the H1 state machine allocation (no more normalizedMethod).

@MihaZupan MihaZupan added this to the 9.0.0 milestone Mar 23, 2024
@MihaZupan MihaZupan self-assigned this Mar 23, 2024
@MihaZupan MihaZupan requested a review from a team March 23, 2024 11:22
@stephentoub stephentoub merged commit d12b12a into dotnet:main Mar 24, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Apr 24, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants