The Computer Language
Benchmarks Game

Erlang HiPE versus Java fastest programs

Always look at the source code.

These are only the fastest programs. Do some of them use manually vectorized SIMD? Look at the other programs. They may seem more-like a fair comparison to you.

binary-trees
source secs mem gz busy cpu load
Erlang HiPE 4.17 385,804 478 11.73 67% 84% 62% 69%
Java 2.48 1,722,848 835 7.88 98% 75% 71% 74%
fannkuch-redux
source secs mem gz busy cpu load
Erlang HiPE 59.08 24,856 1038 234.23 99% 99% 99% 99%
Java 10.64 35,192 1282 41.91 99% 98% 99% 97%
spectral-norm
source secs mem gz busy cpu load
Erlang HiPE 11.18 36,732 747 44.14 98% 99% 99% 99%
Java 1.63 39,304 756 6.22 95% 97% 95% 95%
regex-redux
source secs mem gz busy cpu load
Erlang HiPE 42.76 3,372,420 1048 61.66 32% 16% 37% 59%
Java 5.58 985,696 929 18.26 81% 77% 84% 85%
pidigits
source secs mem gz busy cpu load
Erlang HiPE 7.94 28,088 562 8.34 8% 88% 2% 7%
Java 0.93 36,552 764 0.98 2% 3% 1% 99%
reverse-complement
source secs mem gz busy cpu load
Erlang HiPE 25.62 2,765,104 1302 68.99 56% 52% 77% 85%
Java 1.54 670,924 2183 3.51 46% 56% 48% 79%
k-nucleotide
source secs mem gz busy cpu load
Erlang HiPE 86.79 855,628 937 239.31 57% 66% 58% 94%
Java 4.98 356,904 1812 16.25 78% 76% 96% 76%
mandelbrot
source secs mem gz busy cpu load
Erlang HiPE 84.88 54,364 806 339.25 100% 100% 100% 100%
Java 4.15 69,136 796 16.29 98% 99% 98% 99%
n-body
source secs mem gz busy cpu load
Erlang HiPE 140.03 24,832 1399 141.22 0% 100% 0% 0%
Java 6.74 35,844 1489 6.82 1% 100% 1% 0%
fasta
source secs mem gz busy cpu load
Erlang HiPE 57.01 25,348 1039 73.11 9% 14% 100% 5%
Java 1.21 44,620 2543 3.58 89% 75% 65% 68%
Erlang HiPE

Erlang/OTP 23 [erts-11.1] [source] [64-bit]
[smp:4:4] [ds:4:4:10] [async-threads:1] [hipe]

Java

openjdk 16 2021-03-16
OpenJDK Runtime Environment (build 16+36-2231)
OpenJDK 64-Bit Server VM (build 16+36-2231, mixed mode, sharing)