-
Notifications
You must be signed in to change notification settings - Fork 18.4k
Closed
Labels
FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.Performance
Milestone
Description
What version of Go are you using (go version
)?
$ go version 1.17.3
Does this issue reproduce with the latest release?
I believe so, but have not yet confirmed.
What operating system and processor architecture are you using (go env
)?
go env
Output
$ go env GOARCH="amd64" GOOS="linux"
What did you do?
I'm running a service that has many http2 clients.
What did you expect to see?
Fewer allocations when reading data from established connections.
What did you see instead?
Around 20-25% of our service's total allocations at times are coming from context.WithCancel
calls made by (*tls.Conn).handshakeContext
.
It looks like every (*tls.Context).Read
call made by http2's ReadFrame
is calling c.Handshake
which calls through to c.handshakeContext
, which begins with a call to context.WithCancel
, which allocates.
alkmc, moredure and pascaldekloe
Metadata
Metadata
Assignees
Labels
FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.Performance