The Computer Language
Benchmarks Game

C# .NET Core programs versus C++ g++

by benchmark task performance

fasta
source secs mem gz cpu cpu load
C# .NET Core 2.06 85,804 2087 7.82 95% 95% 97% 94%
C++ g++ 1.48 4,176 2313 5.25 89% 90% 88% 89%
pidigits
source secs mem gz cpu cpu load
C# .NET Core 3.01 39,292 1026 3.01 100% 0% 1% 1%
C++ g++ 1.89 3,868 508 1.89 100% 1% 2% 1%
regex-redux
source secs mem gz cpu cpu load
C# .NET Core 30.01 1,634,216 856 104.34 88% 78% 92% 91%
C++ g++ 17.14 220,088 853 25.22 95% 3% 51% 1%
fannkuch-redux
source secs mem gz cpu cpu load
C# .NET Core 19.09 39,228 1172 75.64 100% 99% 100% 99%
C++ g++ 10.35 2,624 980 40.60 99% 99% 100% 95%
k-nucleotide
source secs mem gz cpu cpu load
C# .NET Core 13.45 219,468 1585 37.40 54% 52% 78% 97%
C++ g++ 7.18 164,052 1252 24.28 83% 83% 93% 83%
reverse-complement
source secs mem gz cpu cpu load
C# .NET Core 1.16 312,124 1580 1.84 14% 49% 37% 69%
C++ g++ 0.60 211,852 2275 0.98 38% 25% 82% 27%
spectral-norm
source secs mem gz cpu cpu load
C# .NET Core 4.04 40,956 878 15.80 98% 97% 98% 98%
C++ g++ 1.99 1,880 1044 7.89 100% 99% 99% 99%
n-body
source secs mem gz cpu cpu load
C# .NET Core 21.70 38,396 1305 21.69 0% 73% 28% 1%
C++ g++ 9.31 1,052 1544 9.30 1% 1% 1% 100%
binary-trees
source secs mem gz cpu cpu load
C# .NET Core 7.15 740,308 851 23.70 85% 83% 82% 85%
C++ g++ 2.36 114,404 809 7.69 86% 71% 87% 85%
mandelbrot
source secs mem gz cpu cpu load
C# .NET Core 6.79 74,336 672 26.78 99% 99% 99% 99%
C++ g++ 1.73 34,064 1002 6.80 98% 98% 98% 99%
C# .NET Core

2.0.0-preview1-005977
"System.GC.Server": true

C++ g++

g++ (Ubuntu 6.3.0-12ubuntu2) 6.3.0 20170406