÷

 Step 1 : Are the Lua programs faster? At a glance.

This chart shows 3 comparisons - Time-used, Memory-used and Code-used ~ speed and size.

Each chart bar shows, for one unidentified benchmark, how much the fastest Lua program used compared to the fastest Java 6 -Xint program.


 Step 2 : Are the Lua programs faster? Approximately.

This table shows 3 comparisons - Time-used, Memory-used and Code-used ~ speed and size.

Each table row shows, for one named benchmark, how much the fastest Lua program used compared to the fastest Java 6 -Xint program.

 Lua used what fraction? used how many times more? 
Benchmark Time Memory Code
 regex-dna1/131/21/2
 k-nucleotide1/51/21/2
 partial-sums1/21/81/2
 mandelbrot±1/111/2
 reverse-complement±±±
 spectral-norm±1/101/2
 fasta±1/8±
 n-body±1/11±
 recursive1/10±
 fannkuch1/8±
 binary-trees±±
 pidigits±±
 nsieve±
 nsieve-bits1/4±

± read the measurements and then read the program source code.

 Step 3 : Are the Lua programs faster? Measurements.

This table shows 5 measurements - CPU Time, Elapsed Time, Memory, Code and ≈ CPU Load ~ speed and size.

For each named benchmark, measurements of the fastest Lua program are shown for comparison against measurements of the fastest Java 6 -Xint program.

Program Source Code CPU secs Elapsed secs Memory KB Code B ≈ CPU Load
 regex-dna 
Lua9.8932,908427  
Java 6 -Xint130.2666,972921  
 k-nucleotide 
Lua35.4338,248613  
Java 6 -Xint174.5968,3121052  
 partial-sums 
Lua7.45900437  
Java 6 -Xint13.197,120711  
 mandelbrot 
Lua3.02868367  
Java 6 -Xint3.689,388665  
 reverse-complement 
Lua8.8543,000538  
Java 6 -Xint8.6357,188592  
 spectral-norm 
Lua727.881,100328  
Java 6 -Xint660.7310,584514  
 fasta 
Lua213.66904993  
Java 6 -Xint146.297,1521240  
 n-body 
Lua586.858721265  
Java 6 -Xint400.619,5561424  
 recursive 
Lua4.86992330  
Java 6 -Xint3.189,752427  
 fannkuch 
Lua3.21864469  
Java 6 -Xint1.687,092555  
 binary-trees 
Lua55.6934,464470  
Java 6 -Xint21.4624,364603  
 pidigits 
Lua0.595,324684  
Java 6 -Xint0.217,716938  
 nsieve 
Lua10.9399,276258  
Java 6 -Xint2.9919,388296  
 nsieve-bits 
Lua23.632,512426  
Java 6 -Xint4.6310,000423  
 chameneos-redux 
No program
Java 6 -Xint0.7310,3321429  

 Step 4 : Are there other Lua programs for these benchmarks?

Remember - those are just the fastest Lua and Java 6 -Xint programs measured on this OS/machine. Check if there are other implementations of these benchmark programs for Lua.

Maybe one of those other Lua programs is fastest on a different OS/machine.

 Step 5 : Are there other faster programs for these benchmarks?

Remember - those are just the fastest Lua and Java 6 -Xint programs measured on this OS/machine. Check if there are faster implementations of these benchmark programs for other programming languages.

Maybe one of those other programs is fastest on a different OS/machine.

 Lua : associative arrays for extensible embedded scripting 

online book "Programming in Lua" by Roberto Ierusalimschy

"the evolution of Lua" (pdf slides)

Lua 5.1.3 Copyright (C) 1994-2008 Lua.org, PUC-Rio

Home Page: http://www.lua.org/

Download: http://www.lua.org/download.html

Revised BSD license

  Home   Flawed   Fastest   License   Help