Patent ID: 8365157

Claim:
A system for early platform dependency preparation of intermediate code representation during bytecode compilation, comprising: a computer server, including a computer hardware, operating system, storage, and virtual machine; an application bytecode that is received at the computer server for execution thereon; and a bytecode compiler that executes on the computer server to receive the application bytecode and compile the application bytecode into resulting native code, wherein the bytecode compiler contains a logic that transforms the bytecode into a high-level intermediate representation (HIR), a logic that optimizes and then transforms the HIR into a medium-level intermediate representation (MIR), a MIR-to-MIR expander that recursively expands the MIR, so that MIR operations therein are adapted to platform conventions of the operating system and the computer hardware, including determining those MIR that can be expressed as a more detailed MIR, expanding those MIR to be more adapted to the platform conventions of the particular platform including the operating system and the computer hardware, optimizing the expanded MIR using a strength reduction method and one or more constant propagation, copy propagation, inlining, locking, escape analysis, or object explosion optimizations, and repeating the determining, expanding and optimizing steps for one or more additional MIR, a MIR-to-LIR transformer that transforms the MIR resulting from the MIR-to-MIR expansion into a low-level intermediate representation (LIR), and transforming the LIR into the native code prior to storing the resulting native code in the storage of the computer server for subsequent use by the system.