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

Add benchmarks #2

Open
Fasjeit opened this issue Aug 17, 2018 · 3 comments
Open

Add benchmarks #2

Fasjeit opened this issue Aug 17, 2018 · 3 comments

Comments

@Fasjeit
Copy link
Owner

Fasjeit commented Aug 17, 2018

Add benchmark using BenchmarkDotNet, compare with go implementation and ssl stream( c#).

@Fasjeit
Copy link
Owner Author

Fasjeit commented Sep 5, 2018

First benchmarks results, way worse than I expected. Clinet-server roundtrip, initialized, NK.

BenchmarkDotNet=v0.11.1, OS=Windows 10.0.17134.285 (1803/April2018Update/Redstone4)
Intel Core i5-8300H CPU 2.30GHz (Coffee Lake), 1 CPU, 8 logical and 4 physical cores
Frequency=2249999 Hz, Resolution=444.4446 ns, Timer=TSC
.NET Core SDK=2.1.402
  [Host]     : .NET Core 2.0.9 (CoreCLR 4.6.26614.01, CoreFX 4.6.26614.01), 64bit RyuJIT
  DefaultJob : .NET Core 2.0.9 (CoreCLR 4.6.26614.01, CoreFX 4.6.26614.01), 64bit RyuJIT

Method N Mean Error StdDev Median Rank
TlsStream 64 37.33 us 0.3262 us 0.3051 us 37.21 us 1
DiscoChannel 64 46.70 us 0.1382 us 0.1293 us 46.63 us 5
TlsStream 128 38.50 us 0.1467 us 0.1300 us 38.48 us 2
DiscoChannel 128 52.19 us 1.0355 us 2.0439 us 51.31 us 7
TlsStream 256 39.85 us 0.1826 us 0.1619 us 39.83 us 3
DiscoChannel 256 62.44 us 0.4118 us 0.3651 us 62.38 us 8
TlsStream 512 41.62 us 0.1990 us 0.1764 us 41.57 us 4
DiscoChannel 512 93.67 us 0.2562 us 0.2397 us 93.65 us 10
TlsStream 1024 47.26 us 0.3124 us 0.2769 us 47.19 us 6
DiscoChannel 1024 151.59 us 1.2438 us 1.1026 us 151.43 us 11
TlsStream 4094 84.30 us 0.5642 us 0.5001 us 84.20 us 9
DiscoChannel 4094 849.07 us 5.7249 us 5.3551 us 848.50 us 12
TlsStream 1048576 11,812.22 us 24.8423 us 22.0220 us 11,802.38 us 13
DiscoChannel 1048576 1,689,719.65 us 7,477.5843 us 6,994.5363 us 1,688,270.08 us 14

@Fasjeit
Copy link
Owner Author

Fasjeit commented Sep 5, 2018

Optimization will be done after #5 will be fixed (when new api will come out).

@Fasjeit
Copy link
Owner Author

Fasjeit commented Sep 23, 2018

After some optimization.

BenchmarkDotNet=v0.11.1, OS=Windows 10.0.17134.285 (1803/April2018Update/Redstone4)
Intel Core i5-8300H CPU 2.30GHz (Coffee Lake), 1 CPU, 8 logical and 4 physical cores
Frequency=2249999 Hz, Resolution=444.4446 ns, Timer=TSC
.NET Core SDK=2.1.402
  [Host]     : .NET Core 2.0.9 (CoreCLR 4.6.26614.01, CoreFX 4.6.26614.01), 64bit RyuJIT
  DefaultJob : .NET Core 2.0.9 (CoreCLR 4.6.26614.01, CoreFX 4.6.26614.01), 64bit RyuJIT

Method N Mean Error StdDev Rank
TlsStream 64 38.67 us 0.2698 us 0.2392 us 1
DiscoChannel 64 39.99 us 0.3142 us 0.2624 us 3
TlsStream 128 39.57 us 0.4722 us 0.4417 us 2
DiscoChannel 128 42.58 us 0.2161 us 0.2022 us 5
TlsStream 256 40.90 us 0.3580 us 0.3349 us 4
DiscoChannel 256 52.17 us 0.8768 us 0.8202 us 8
TlsStream 512 43.71 us 0.2798 us 0.2617 us 6
DiscoChannel 512 69.32 us 0.6894 us 0.6449 us 9
TlsStream 1024 49.84 us 0.3354 us 0.3137 us 7
DiscoChannel 1024 99.16 us 0.7823 us 0.6935 us 11
TlsStream 4094 88.74 us 2.0408 us 1.9089 us 10
DiscoChannel 4094 345.52 us 6.7648 us 6.6439 us 12
TlsStream 1048576 12,062.76 us 61.9658 us 54.9310 us 13
DiscoChannel 1048576 107,509.30 us 2,037.8748 us 1,906.2292 us 14

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

No branches or pull requests

1 participant