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

共享指向分析的 ART(扩展摘要)

The ART of Sharing Points-to Analysis (Extended Abstract)

Shashin Halalingaiah, Vijay Sundaresan, Daryl Maier, V. Krishna Nandivada

AI总结:

针对跨编译器共享高精度指向分析结果时的信任与效率问题,本文提出 ART 模板,通过生产者编码和消费者安全校验重生成流敏感结果,并在 Soot 与 OpenJ9 中验证。

摘要:

诸如指向分析之类的数据流分析可以极大地提高其他分析的精度,并帮助执行强大的代码优化。然而,对大型程序进行全程序指向分析往往代价高昂——无论在时间还是内存方面都是如此。因此,许多编译器(包括静态编译器和 JIT 编译器)以及程序分析工具往往采用速度更快但更为保守的指向分析,以提升可用性。作为这种以精度换取性能的替代方案,已有多种技术被提出:在静态分析器中提前执行精确但代价高昂的定点指向分析,存储其结果,然后将这些结果传输给可能需要它们的独立编译或程序分析阶段。然而,一个根本性的安全性问题影响着所有此类技术——编译器(或程序分析工具)能否信任由另一个编译器或工具生成的指向分析结果?在本工作中,我们在关注性能效率问题的同时,解决这一信任问题。我们提出了 ART:Analysis-results Representation Template(分析结果表示模板),这是一种新颖的方案,能够高效且简洁地编码由静态分析器计算得到的流敏感、上下文不敏感指向分析结果,以供任何可能从这种高精度指向分析中受益的独立系统使用。我们的方案包含两个组件:(i)一个生产者,能够静态执行代价高昂的指向分析并简洁地对其进行编码;(ii)一个消费者,在接收到这些编码结果后,如果判定其安全,就可以重新生成由该 art 编码的指向分析结果。我们通过在 Soot 中实现一个生产者,并在 Soot 和 Eclipse OpenJ9 JIT 编译器中实现两个消费者,展示了 ART 的用法。我们基于 DaCapo 和 SPECjvm2008 测试套件中的多个基准测试程序对实现进行了评估。

英文摘要:

Data-flow analyses like points-to analysis can vastly improve the precision of other analyses, and help perform powerful code optimizations. However, whole-program points-to analysis of large programs tend to be expensive - both in terms of time and memory. Consequently, many compilers (both static and JIT) and program-analysis tools tend to employ faster - but more conservative - points-to analysis to improve usability. As an alternative to such trading of precision for performance, various techniques have been proposed to perform precise yet expensive fixed-point points-to analyses ahead of time in a static analyzer, store the results, and then transmit them to independent compilation/program-analysis stages that may need them. However, an underlying concern of safety affects all such techniques - can a compiler (or program analysis tool) trust the points-to analysis results generated by another compiler/tool? In this work, we address this issue of trust, while keeping the issues of performance efficiency in mind. We propose ART: Analysis-results Representation Template - a novel scheme to efficiently and concisely encode results of flow-sensitive, context-insensitive points-to analysis computed by a static analyzer for use in any independent system that may benefit from such a highly precise points-to analysis. Our scheme has two components: (i) a producer that can statically perform expensive points-to analysis and encode the same concisely. (ii) a consumer that, on receiving such encoded results, can regenerate the points-to analysis results encoded by the artwork if it is deemed safe. We demonstrate the usage of ART by implementing a producer (in Soot) and two consumers (in Soot and the Eclipse OpenJ9 JIT compiler). We evaluate our implementation over various benchmarks from the DaCapo and SPECjvm2008 suites.

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

↑