Friday, March 27, 2009

Retarget table just in time compiler (Linux, c++)

A Just In Time compiler is one in which the compilation to native machine code occurs just prior to execution. These compilers can generate more efficient code than a static compiler, since it has more knowledge about the context and execution of the program. With the increase in use of multiprocessors, a necessity to retarget compilers to be compatible to different platforms has arised. Hence an attempt to retarget a JIT compiler to generate efficient target independent codes is made. To achieve target independent codes, Low Level Virtual Machine (LLVM) byte code representation is used. This representation makes use of a low-level, strongly typed, three-address, load-store code representation. LLVM is in Static Single Assignment form that is machine independent, but can handle certain machine specific features also.
The input to the compiler is a C program compiled to LLVM byte code. As the LLVM is target-independent, many phases of code generation can be target independent, making the JIT easily retarget able to new platforms (targets) without changing the code generator. Thus the code generation process is separated into a series of modular stages, simplifying addition of new passes and replacement of the existing one. The code generation is split into few target independent phases namely: Live Variable Analysis, Register Allocation and Prologue/Epilogue phases. This can be used to provide a flexible host for future research in runtime optimization for programs written in languages that are traditionally compiled statically.

Project Members : Abdul Muthalib & Taher Bharmal
Project Guide : Ms. Swatika

No comments:

ss_blog_claim=b2020e0f26362b8071fda24b7fed8308 ss_blog_claim=b2020e0f26362b8071fda24b7fed8308