Affiliation:
1. IBM T.J. Watson Research Center, P.O. Box 704, Yorktown Heights, NY
Abstract
Dynamic class loading during program execution in the Java Programming Language is an impediment for generating code that is as efficient as code generated using static whole-program analysis and optimization. Whole-program analysis and optimization is possible for languages, such as C++, that do not allow new classes and/or methods to be loaded during program execution. One solution for performing whole-program analysis and
avoiding incorrect execution after a new class is loaded is to invalidate and recompile affected methods. Runtime invalidation and recompilation mechanisms can be expensive in both space and time, and, therefore, generally restrict optimization.
To address these drawbacks, we propose a new framework, called the
extant analysis framework
, for interprocedural optimization of programs that support dynamic class (or method)loading. Given a set of classes comprising the
closed world
, we perform an offline static analysis
which partitions references into two categories:(1)
unconditionally extant
references which point only to objects whose runtime type is guaranteed to be in the closed world; and (2)
conditionally extant
references which point to objects whose runtime type is not guaranteed to be in the closed world. Optimizations solely dependent on the first categorycan be statically performed, and are guaranteed to be correct even with any future class/method loading. Optimizations dependent on the second category are guarded by dynamic tests, called
extant safety tests
, for correct execution behavior.We describe the properties for extant safety tests, and provide algorithms for their generation and placement.
Publisher
Association for Computing Machinery (ACM)
Subject
Computer Graphics and Computer-Aided Design,Software
Cited by
13 articles.
订阅此论文施引文献
订阅此论文施引文献,注册后可以免费订阅5篇论文的施引文献,订阅后可以查看论文全部施引文献