Efficient Classloading Strategies for Interprocedural Analyses in the Presence of Dynamic Classloading

  • Authors:
  • Kyungwoo Lee;Qasim Ali;Samuel P. Midkiff

  • Affiliations:
  • Purdue University;Purdue University;Purdue University

  • Venue:
  • WODA '07 Proceedings of the 5th International Workshop on Dynamic Analysis
  • Year:
  • 2007

Quantified Score

Hi-index 0.00

Visualization

Abstract

In the presence of dynamic classloading, performing interprocedural analysis (IPA) too early can lead to repeatedly performing the IPA as new classes are loaded, while performing it too late will cause a performance degradation by running unoptimized code for too long. This paper investigates how programs load classes and how this affects the performance when performing IPA. From this investigation, two classloading techniques are described and evaluated. We first describe a classloader that eagerly preloads classes whose names appear in the constant pool. By loading classes as early as possible, the preloading classloader reduces the chances of new classes being loaded after an IPA is performed, and thus can improve performance by reducing the number of IPAs performed. We next describe a technique that delays the IPA, causing it to be performed late enough to dramatically reduce the need for re-analyses and early enough to obtain the benefits of the IPA. When these two classloading techniques are used with a real IPA . an escape analysis to enforce sequential consistency in Java programs . the speedups relative to the default nonpreloading classloader are 1.87 and 2.30 respectively, on average.