Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

crypto/tls: performance slow on windows/386 #40575

Open
RichardLaos opened this issue Aug 4, 2020 · 2 comments
Open

crypto/tls: performance slow on windows/386 #40575

RichardLaos opened this issue Aug 4, 2020 · 2 comments
Labels
NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. OS-Windows
Milestone

Comments

@RichardLaos
Copy link

RichardLaos commented Aug 4, 2020

What version of Go are you using (go version)?

c:\Go386\go\bin>go version
go version go1.14.6 windows/386

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

go env Output
c:\Go386\go\bin>go env
set GO111MODULE=
set GOARCH=386
set GOBIN=
set GOCACHE=C:\Users\rlaos\AppData\Local\go-build
set GOENV=C:\Users\rlaos\AppData\Roaming\go\env
set GOEXE=.exe
set GOFLAGS=
set GOHOSTARCH=386
set GOHOSTOS=windows
set GOINSECURE=
set GONOPROXY=
set GONOSUMDB=
set GOOS=windows
set GOPATH=C:\Users\rlaos\go
set GOPRIVATE=
set GOPROXY=https://proxy.golang.org,direct
set GOROOT=c:\Go386\go
set GOSUMDB=sum.golang.org
set GOTMPDIR=
set GOTOOLDIR=c:\Go386\go\pkg\tool\windows_386
set GCCGO=gccgo
set GO386=sse2
set AR=ar
set CC=gcc
set CXX=g++
set CGO_ENABLED=1
set GOMOD=
set CGO_CFLAGS=-g -O2
set CGO_CPPFLAGS=
set CGO_CXXFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2
set PKG_CONFIG=pkg-config
set GOGCCFLAGS=-m32 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\Users\rlaos\AppData\Local\Temp\go-build312903914=/tmp/go-build -gno-record-gcc-switches

What did you do?

Ran crypto/tls BenchmarkThroughput

What did you expect to see?

Benchmark results similar to other platforms

What did you see instead?

Slower than expected benchmarks

c:\Go386\go\bin>go test crypto/tls -bench BenchmarkThroughput
goos: windows
goarch: 386
pkg: crypto/tls
BenchmarkThroughput/MaxPacket/1MB/TLSv12-8            12          85109717 ns/op          12.32 MB/s
BenchmarkThroughput/MaxPacket/1MB/TLSv13-8            12          90715292 ns/op          11.56 MB/s
BenchmarkThroughput/MaxPacket/2MB/TLSv12-8             6         182682667 ns/op          11.48 MB/s
BenchmarkThroughput/MaxPacket/2MB/TLSv13-8             6         167867017 ns/op          12.49 MB/s
BenchmarkThroughput/MaxPacket/4MB/TLSv12-8             3         350089833 ns/op          11.98 MB/s
BenchmarkThroughput/MaxPacket/4MB/TLSv13-8             3         344346567 ns/op          12.18 MB/s
BenchmarkThroughput/MaxPacket/8MB/TLSv12-8             2         752240000 ns/op          11.15 MB/s
BenchmarkThroughput/MaxPacket/8MB/TLSv13-8             2         740517600 ns/op          11.33 MB/s
BenchmarkThroughput/MaxPacket/16MB/TLSv12-8            1        1527828300 ns/op          10.98 MB/s
BenchmarkThroughput/MaxPacket/16MB/TLSv13-8            1        1508538200 ns/op          11.12 MB/s
BenchmarkThroughput/MaxPacket/32MB/TLSv12-8            1        2851125400 ns/op          11.77 MB/s
BenchmarkThroughput/MaxPacket/32MB/TLSv13-8            1        2923947500 ns/op          11.48 MB/s
BenchmarkThroughput/MaxPacket/64MB/TLSv12-8            1        5856113800 ns/op          11.46 MB/s
BenchmarkThroughput/MaxPacket/64MB/TLSv13-8            1        5691605000 ns/op          11.79 MB/s
BenchmarkThroughput/DynamicPacket/1MB/TLSv12-8                13          93452846 ns/op          11.22 MB/s
BenchmarkThroughput/DynamicPacket/1MB/TLSv13-8                12          89222967 ns/op          11.75 MB/s
BenchmarkThroughput/DynamicPacket/2MB/TLSv12-8                 6         174278867 ns/op          12.03 MB/s
BenchmarkThroughput/DynamicPacket/2MB/TLSv13-8                 6         184205067 ns/op          11.38 MB/s
BenchmarkThroughput/DynamicPacket/4MB/TLSv12-8                 3         371415800 ns/op          11.29 MB/s
BenchmarkThroughput/DynamicPacket/4MB/TLSv13-8                 3         345000733 ns/op          12.16 MB/s
BenchmarkThroughput/DynamicPacket/8MB/TLSv12-8                 2         741865300 ns/op          11.31 MB/s
BenchmarkThroughput/DynamicPacket/8MB/TLSv13-8                 2         690233200 ns/op          12.15 MB/s
BenchmarkThroughput/DynamicPacket/16MB/TLSv12-8                1        1449565400 ns/op          11.57 MB/s
BenchmarkThroughput/DynamicPacket/16MB/TLSv13-8                1        1499601000 ns/op          11.19 MB/s
BenchmarkThroughput/DynamicPacket/32MB/TLSv12-8                1        3050847000 ns/op          11.00 MB/s
BenchmarkThroughput/DynamicPacket/32MB/TLSv13-8                1        2980453500 ns/op          11.26 MB/s
BenchmarkThroughput/DynamicPacket/64MB/TLSv12-8                1        5588348900 ns/op          12.01 MB/s
BenchmarkThroughput/DynamicPacket/64MB/TLSv13-8                1        5793084600 ns/op          11.58 MB/s
PASS
ok      crypto/tls      69.500s
@RichardLaos RichardLaos changed the title go version crypto/tls performance slow on windows/x386 Aug 4, 2020
@RichardLaos RichardLaos changed the title crypto/tls performance slow on windows/x386 crypto/tls performance slow on windows/386 Aug 4, 2020
@toothrot toothrot changed the title crypto/tls performance slow on windows/386 x/crypto/tls: performance slow on windows/386 Aug 4, 2020
@gopherbot gopherbot added this to the Unreleased milestone Aug 4, 2020
@toothrot toothrot added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Aug 4, 2020
@toothrot
Copy link
Contributor

toothrot commented Aug 4, 2020

/cc @FiloSottile

@FiloSottile FiloSottile changed the title x/crypto/tls: performance slow on windows/386 crypto/tls: performance slow on windows/386 Aug 4, 2020
@RichardLaos
Copy link
Author

RichardLaos commented Aug 5, 2020

The benchmark is similar whether this is a native 32bit environment or the 386 release in a 64bit environment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. OS-Windows
Projects
None yet
Development

No branches or pull requests

3 participants