arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2308.16566cs.PL
收藏

比较GraalVM Native Image中的快速类型分析与指向分析

Comparing Rapid Type Analysis with Points-To Analysis in GraalVM Native Image

David Kozák, Vojin Jovanovic, Codruţ Stancu, Tomáš Vojnar, Christian Wimmer

AI总结:

本研究探讨在GraalVM Native Image中用快速类型分析(RTA)替代指向分析,通过并行化、增量化和堆快照扩展,将Spring Petclinic的分析时间降低64%,构建时间降低35%,但镜像大小增加15%。

摘要:

全程序分析是支持高级编译器优化的关键技术。此类方法的一个重要示例是指向分析,提前(AOT)编译器使用它来发现在至少一条程序路径上使用的程序元素(类、方法、字段)。GraalVM Native Image使用指向分析来优化Java应用程序,这是构建中耗时的步骤。我们探讨了通过将指向分析替换为快速类型分析(RTA)来改善分析时间的程度,RTA通过允许更多不精确性来更快地计算可达元素。我们提出了对先前RTA方法的几种扩展:使其并行化、增量式,并支持堆快照。我们进行了广泛的实验评估,比较使用RTA代替指向分析的效果,其中RTA使我们能够将Spring Petclinic(Spring框架的流行演示应用程序)的分析时间减少64%,整体构建时间减少35%,但代价是由于不精确性导致镜像大小增加15%。

英文摘要:

Whole-program analysis is an essential technique that enables advanced compiler optimizations. An important example of such a method is points-to analysis used by ahead-of-time (AOT) compilers to discover program elements (classes, methods, fields) used on at least one program path. GraalVM Native Image uses a points-to analysis to optimize Java applications, which is a time-consuming step of the build. We explore how much the analysis time can be improved by replacing the points-to analysis with a rapid type analysis (RTA), which computes reachable elements faster by allowing more imprecision. We propose several extensions of previous approaches to RTA: making it parallel, incremental, and supporting heap snapshotting. We present an extensive experimental evaluation of the effects of using RTA instead of points-to analysis, in which RTA allowed us to reduce the analysis time for Spring Petclinic, a popular demo application of the Spring framework, by 64% and the overall build time by 35% at the cost of increasing the image size due to the imprecision by 15%.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑