Abstract
Just-in-Time(JIT) compiler is a well-known method to improve the runtime performance of computer programs in virtual machines. Since byte code(virtual machine code) is slower as interpreted than compiled to native code, JIT compiler will compile byte code to physical machine code in advance in order to run faster. To speed up the virtual machine performance, the virtual machine will provide the Just-in-Time compiler for translating and optimizing the byte code to intended CPU machine code. In this dissertation, we support the Trace-granularity JIT compiler in Android which has the following property: • The byte code is interpreted with profiling to identify hot trace. • The compiled fragments are chained together for speeding up performance. • The compilation minimizes the memory usage critical for embedded devices. • The compiler is very rapidly return of performance boost once hotness detected. To support the JIT compiler for Android on an indigenous platform, we design a special JIT compilation flow for an indigenous platform. The JIT compiler will translate the Dalvik byte code to the indigenous platform machine code. In addition, the JIT compiler provides optimizations, such as constant propagation, loop-invariant code motion, redundant branch elimination by considering two level intermediate representations. We have implemented our JIT compiler design on Andes AG101 and AG102 developing boards and performed experiments to obtain the speeding up of performance in Dalvik virtual machine. The geometric average for selected benchmark CaffeineMark 3.0 is 4.5x and the average speed up on 0xbench benchmark is 5x over then C-stub interpreter version without JIT compiler. In addition to evaluating the JIT compiler robustness, we also take the applications from the Android Market and list the applications which runs with JIT compiler.