Dynamic compilation and optimization are widely used in heterogenous comput
ing environments, in which an intermediate form of the code is compiled to
native code during execution. An important tradeoff exists between the amou
nt of time spent dynamically optimizing the program and the running time of
the program. The time to perform dynamic optimizations can cause significa
nt delays during execution and also prohibit performance gains that result
from more complex optimization.
In this research, we present an annotation framework that substantially red
uces compilation overhead of Java programs. Annotations consist of analysis
information collected off-line and are incorporated into Java programs. Th
e annotations are then used by dynamic compilers to guide optimization. The
annotations we present reduce compilation overhead incurred at all stages
of compilation and optimization as well as enable complex optimizations to
be performed dynamically. On average, our annotation optimizations reduce o
ptimized compilation overhead by 78% and enable speedups of 7% on average f
or the programs examined.