You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* args.go GetBool(): use switch with string casting
This should be optimized by Go compiler itself so the b2s() call is not needed.
It was previously done by this but changed in
1e7885e
* header.go Referer() optimize
Use direct peekArgBytes() instead of PeekBytes() that will check for special headers
* header_timing_test.go BenchmarkRequestHeaderPeekBytesSpecialHeader
The old BenchmarkRequestHeaderPeekBytesCanonical and BenchmarkRequestHeaderPeekBytesNonCanonical are in fact just measured the header normalization.
But it's anyway is benchmarked separately.
Results was almost the same: 1.5 ns/op.
Instead, let's reuse the benches to find a difference between peeking of special (Host, CT) and custom headers.
0 commit comments