The Computer Language
Benchmarks Game

all Swift programs & measurements

Swift version 4.0 (swift-4.0-RELEASE)
Target: x86_64-unknown-linux-gnu

source secs N mem gz cpu cpu load
binary-trees  #9 0.02  7 ? 997 0.02 0% 33% 0% 100%
binary-trees  #9 0.05  14 ? 997 0.10 40% 50% 50% 80%
binary-trees  #9 4.96  21 192,596 997 13.89 60% 63% 61% 99%
source secs N mem gz cpu cpu load
binary-trees  0.58  7 ? 714 ? 0% 0% 91% 7%
binary-trees  0.28  14 1,196 714 0.75 89% 41% 59% 86%
binary-trees  50.67  21 737,228 714 149.47 96% 67% 63% 72%
source secs N mem gz cpu cpu load
fannkuch-redux  #3 0.08  10 ? 1102 0.25 88% 50% 88% 88%
fannkuch-redux  #3 0.76  11 7,964 1102 2.98 99% 99% 97% 99%
fannkuch-redux  #3 10.20  12 9,784 1102 40.28 100% 99% 98% 98%
source secs N mem gz cpu cpu load
fannkuch-redux  0.35  10 1,520 451 0.34 0% 0% 0% 100%
fannkuch-redux  4.13  11 7,312 451 4.12 0% 1% 100% 3%
fannkuch-redux  56.49  12 4,420 451 56.47 0% 1% 100% 1%
source secs N mem gz cpu cpu load
fasta  #2 0.04  250,000 ? 1953 0.05 40% 67% 40% 0%
fasta  #2 0.32  2,500,000 1,120 1953 0.45 50% 59% 31% 0%
fasta  #2 2.81  25,000,000 10,728 1953 4.26 47% 48% 30% 28%
source secs N mem gz cpu cpu load
fasta  0.13  250,000 ? 1527 0.12 0% 100% 0% 0%
fasta  1.18  2,500,000 7,336 1527 1.17 100% 3% 1% 0%
fasta  11.42  25,000,000 7,472 1527 11.42 1% 1% 0% 100%
source secs N mem gz cpu cpu load
fasta  #3 0.12  250,000 ? 2096 0.12 67% 33% 0% 33%
fasta  #3 0.33  2,500,000 1,328 2096 0.84 72% 63% 70% 59%
fasta  #3 2.32  25,000,000 34,356 2096 7.62 76% 79% 83% 93%
source secs N mem gz cpu cpu load
k-nucleotide  #2 1.43  250,000 65,560 1366 2.00 66% 20% 20% 50%
k-nucleotide  #2 3.40  2,500,000 77,272 1366 8.81 70% 71% 58% 71%
k-nucleotide  #2 20.73  25,000,000 246,548 1366 76.47 94% 94% 90% 92%
source secs N mem gz cpu cpu load
k-nucleotide  1.26  250,000 54,344 1231 1.89 20% 24% 55% 54%
k-nucleotide  3.37  2,500,000 73,476 1231 8.98 57% 71% 84% 57%
k-nucleotide  23.99  25,000,000 177,880 1231 78.61 97% 77% 77% 78%
source secs N mem gz cpu cpu load
mandelbrot  #3 0.02  1,000 ? 1136 0.07 100% 100% 67% 67%
mandelbrot  #3 0.23  4,000 1,368 1136 0.85 95% 95% 95% 100%
mandelbrot  #3 3.32  16,000 41,748 1136 13.19 100% 99% 99% 99%
source secs N mem gz cpu cpu load
mandelbrot  0.22  1,000 1,532 394 0.21 0% 0% 5% 95%
mandelbrot  3.26  4,000 7,448 394 3.25 1% 100% 1% 1%
mandelbrot  51.76  16,000 7,416 394 51.75 1% 100% 0% 0%
source secs N mem gz cpu cpu load
n-body  #6 0.25  500,000 1,588 1194 0.24 8% 100% 0% 4%
n-body  #6 2.38  5,000,000 7,292 1194 2.38 100% 0% 1% 1%
n-body  #6 23.76  50,000,000 7,292 1194 23.75 100% 0% 1% 0%
source secs N mem gz cpu cpu load
n-body  #7 0.26  500,000 1,740 1445 0.25 100% 4% 0% 0%
n-body  #7 2.41  5,000,000 15,164 1445 2.40 0% 0% 3% 100%
n-body  #7 23.88  50,000,000 15,384 1445 23.87 1% 1% 1% 100%
source secs N mem gz cpu cpu load
n-body  #8 0.26  500,000 1,096 1346 0.26 4% 100% 0% 0%
n-body  #8 2.42  5,000,000 15,168 1346 2.41 100% 2% 1% 0%
n-body  #8 23.97  50,000,000 15,284 1346 23.96 1% 100% 1% 0%
source secs N mem gz cpu cpu load
n-body  #2 0.31  500,000 1,036 1192 0.31 3% 100% 0% 0%
n-body  #2 3.07  5,000,000 7,348 1192 3.06 1% 100% 1% 2%
n-body  #2 30.64  50,000,000 7,368 1192 30.63 1% 100% 0% 0%
source secs N mem gz cpu cpu load
n-body  #3 2.04  500,000 7,352 1204 2.02 100% 0% 0% 1%
n-body  #3 20.22  5,000,000 7,400 1204 20.22 1% 0% 100% 0%
n-body  #3 201.80  50,000,000 7,368 1204 201.76 1% 1% 0% 100%
source secs N mem gz cpu cpu load
n-body  #5 0.23  500,000 1,052 1253 0.22 4% 0% 100% 5%
n-body  #5 2.21  5,000,000 7,396 1253 2.20 100% 0% 1% 1%
n-body  #5 21.96  50,000,000 7,396 1253 21.95 1% 100% 1% 0%
source secs N mem gz cpu cpu load
n-body  #4 0.25  500,000 1,752 1357 0.24 0% 100% 0% 0%
n-body  #4 2.34  5,000,000 15,284 1357 2.33 1% 100% 0% 0%
n-body  #4 23.25  50,000,000 15,300 1357 23.24 100% 0% 1% 1%
source secs N mem gz cpu cpu load
pidigits  #2 0.09  2,000 ? 601 0.07 0% 0% 100% 0%
pidigits  #2 0.61  6,000 7,300 601 0.60 3% 100% 0% 2%
pidigits  #2 1.75  10,000 8,532 601 1.75 100% 1% 1% 0%
pidigits  Make Error  2,000
source secs N mem gz cpu cpu load
regex-redux  #2 0.95  50,000 22,860 671 0.95 1% 2% 100% 1%
regex-redux  #2 9.50  500,000 90,464 671 9.49 100% 1% 1% 1%
regex-redux  #2 94.00  5,000,000 695,688 671 93.94 7% 40% 2% 59%
source secs N mem gz cpu cpu load
regex-redux  0.76  50,000 23,764 715 1.41 86% 1% 1% 99%
regex-redux  7.61  500,000 110,484 715 14.16 1% 88% 2% 98%
regex-redux  75.47  5,000,000 882,900 715 141.92 90% 2% 1% 100%
regex-redux  #3 Bad Output  50,000
source secs N mem gz cpu cpu load
reverse-complement  0.08  250,000 ? 1287 ? 11% 11% 11% 90%
reverse-complement  0.49  2,500,000 ? 1287 ? 12% 6% 17% 80%
reverse-complement  0.86  25,000,000 210,216 1287 1.03 79% 2% 1% 42%
source secs N mem gz cpu cpu load
spectral-norm  #3 0.05  500 ? 601 0.16 100% 80% 67% 80%
spectral-norm  #3 1.20  3,000 8,316 601 4.74 100% 99% 100% 98%
spectral-norm  #3 3.98  5,500 11,292 601 15.82 100% 100% 100% 100%
source secs N mem gz cpu cpu load
spectral-norm  0.15  500 ? 438 0.15 0% 0% 0% 94%
spectral-norm  4.85  3,000 15,072 438 4.84 2% 1% 100% 1%
spectral-norm  16.19  5,500 16,604 438 16.18 100% 1% 1% 1%