This section provides a performance comparison between interpreted-only mode and JIT compilation mode on loops with different operations. The JIT compiler improves performance a lot!
If you compare testing results between interpreted-only mode and JIT compilation mode,
you will see performance improvements produced by the JIT compiler.
This table provides execution time of different "int" loops per step in nanoseconds:
int int
Interpreted JIT
Only Compilation
Empty loop 16 1
Assignment: x=i 14 2
Shift: x=i<<1 17 1
Add: x=i+i 17 1
Multipply: x=i*3 17 1
Divide: x=i/3 19 14
This table provides execution time of different "long" loops per step in nanoseconds:
long long
Interpreted JIT
Only Compilation
Empty loop 25 2
Assignment: x=i 24 3
Shift: x=i<<1 30 4
Add: x=i+i 34 3
Multipply: x=i*3 38 4
Divide: x=i/3 53 24