The Computer Language
Benchmarks Game

JavaScript V8 programs versus Java

by benchmark task performance

regex-dna
secs KB gz cpu cpu load
JavaScript V8 3.45 642,500 405 3.44 0% 1% 2% 100%
Java 21.40 575,372 1284 21.39 1% 0% 1% 100%
spectral-norm
secs KB gz cpu cpu load
JavaScript V8 15.71 13,196 361 15.70 1% 0% 1% 100%
Java 16.22 32,332 950 16.22 0% 1% 1% 100%
fannkuch-redux
secs KB gz cpu cpu load
JavaScript V8 74.57 11,060 539 74.54 1% 0% 0% 100%
Java 69.27 47,784 1282 69.25 1% 0% 0% 100%
n-body
secs KB gz cpu cpu load
JavaScript V8 33.95 11,936 1287 33.94 1% 0% 0% 100%
Java 22.68 30,056 1424 22.67 0% 0% 1% 100%
k-nucleotide
secs KB gz cpu cpu load
JavaScript V8 114.18 57,020 1249 114.05 0% 1% 1% 100%
Java 34.83 1,124,104 1844 34.79 1% 1% 0% 100%
reverse-complement
secs KB gz cpu cpu load
JavaScript V8 7.77 403,136 787 7.76 2% 0% 0% 100%
Java 1.70 474,400 745 1.70 1% 1% 3% 99%
fasta
secs KB gz cpu cpu load
JavaScript V8 25.51 43,104 956 25.47 0% 0% 1% 100%
Java 5.15 31,376 1507 5.14 1% 1% 0% 100%
binary-trees
secs KB gz cpu cpu load
JavaScript V8 49.00 937,048 467 48.92 0% 1% 0% 100%
Java 7.39 414,024 583 7.38 1% 1% 1% 100%
fasta-redux
secs KB gz cpu cpu load
  No program contribute your program
Java 0.22 1,704 1443 0.20 5% 0% 0% 100%
pidigits
secs KB gz cpu cpu load
  No program contribute your program
Java 0.33 2,020 938 0.30 0% 0% 3% 100%
mandelbrot
secs KB gz cpu cpu load
JavaScript V8   Bad Output
Java 0.32 1,664 796 0.31 6% 9% 0% 100%
JavaScript V8

V8 version 4.6.0 (candidate) [console: dumb]

Java

java version "1.8.0_45"
Java(TM) SE Runtime Environment (build 1.8.0_45-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.45-b02, mixed mode)