The Computer Language
Benchmarks Game

Haskell GHC programs versus C gcc

by benchmark task performance

fannkuch-redux
source secs mem gz cpu cpu load
Haskell GHC 15.40 3,368 1113 60.35 100% 99% 99% 95%
C gcc 8.66 980 910 34.22 100% 97% 100% 100%
spectral-norm
source secs mem gz cpu cpu load
Haskell GHC 4.04 4,132 987 15.71 97% 100% 95% 97%
C gcc 2.00 1,300 569 7.89 99% 99% 100% 99%
n-body
source secs mem gz cpu cpu load
Haskell GHC 21.43 3,996 1883 84.71 98% 100% 99% 98%
C gcc 9.12 1,176 1490 9.12 1% 100% 2% 2%
reverse-complement
source secs mem gz cpu cpu load
Haskell GHC 1.40 128,808 1020 1.46 2% 5% 2% 99%
C gcc 0.48 200,492 820 0.66 4% 19% 25% 98%
k-nucleotide
source secs mem gz cpu cpu load
Haskell GHC 35.01 644,356 1486 122.09 86% 87% 89% 97%
C gcc 6.67 130,160 1506 19.33 76% 50% 92% 75%
fasta
source secs mem gz cpu cpu load
Haskell GHC 9.36 5,044 969 9.74 2% 3% 2% 99%
C gcc 1.32 2,912 2268 5.25 100% 99% 100% 99%
mandelbrot
source secs mem gz cpu cpu load
Haskell GHC 11.69 38,472 782 46.64 100% 100% 100% 100%
C gcc 1.64 29,424 1135 6.53 99% 100% 100% 100%
binary-trees
source secs mem gz cpu cpu load
Haskell GHC 24.81 512,320 538 51.11 35% 39% 98% 36%
C gcc 2.44 133,956 836 7.57 80% 65% 68% 100%
pidigits
source secs mem gz cpu cpu load
Haskell GHC   Make Error
C gcc 0.06 ? 452 0.06 86% 14% 0% 83%
regex-redux
source secs mem gz cpu cpu load
Haskell GHC   Bad Output
C gcc 0.02 ? 1230 0.05 100% 100% 50% 100%
Haskell GHC

The Glorious Glasgow Haskell Compilation System, version 8.2.1

C gcc

gcc (Ubuntu 7.2.0-8ubuntu3) 7.2.0