paperbot · PL 论文追踪

全部论文 待读 收藏

P2 SHARP: fast incremental context-sensitive pointer analysis for Java

SHARP:面向 Java 的快速增量上下文敏感指针分析
OOPSLA 6(OOPSLA1)2022匹配度 3/10 · 该论文属于静态分析领域的增量指针分析,但未涉及 LLM/Agent 与静态分析的交叉,也不属于浮点程序分析或贝叶斯程序分析方向;与用户核心研究问题仅有泛化的 PL 背景关联,匹配度较低。引用 21 inbox
Bozhen Liu, Jeff Huang
crossref: 2026-09-10

AI 速览

一句话:提出首个支持代码增删的上下文敏感增量指针分析算法 SHARP,兼容 k-CFA 与 k-obj,并可高效并行化。

本文针对增量指针分析中上下文敏感性缺失的问题,提出 SHARP——一种面向真实大型复杂 Java 程序的增量上下文敏感指针分析算法。据作者所知,SHARP 是首个在先进增量指针分析框架中处理上下文敏感性的算法,且同时适用于 k-CFA 与 k-obj,并能应对包括语句添加与删除在内的代码修改。为在保持精度的同时提升可扩展性,SHARP 解决了可靠性、冗余计算消除与并行化等关键技术挑战。作者在大型流行 Java 项目及其代码提交上进行了广泛实证评估:增量算法处理一次真实代码提交平均仅需 31 秒(k-CFA 与 k-obj),性能与最先进的增量上下文不敏感指针分析相当;并行化进一步将八核机器上的平均处理时间降至每次提交 18 秒。

问题
现有增量指针分析仅支持上下文不敏感分析,难以在代码修改(含语句增删)下高效地维持上下文敏感分析的精度与可扩展性。
方法
SHARP 通过应对可靠性、冗余计算与并行化等挑战,实现支持 k-CFA 与 k-obj 的增量上下文敏感指针分析。
评估
在大型流行 Java 项目及其代码提交上进行广泛实证评估,平均 31 秒处理一次真实提交,与最先进的增量上下文不敏感分析性能相当,八核并行下平均降至 18 秒。
原文摘要(Abstract)

We present SHARP, an incremental context-sensitive pointer analysis algorithm that scales to real-world large complex Java programs and can also be efficiently parallelized. To our knowledge, SHARP is the first algorithm to tackle context-sensitivity in the state-of-the-art incremental pointer analysis (with regards to code modifications including both statement additions and deletions), which applies to both k-CFA and k-obj. To achieve it, SHARP tackles several technical challenges: soundness, redundant computations, and parallelism to improve scalability without losing precision. We conduct an extensive empirical evaluation of SHARP on large and popular Java projects and their code commits, showing impressive performance improvement: our incremental algorithm only requires on average 31 seconds to handle a real-world code commit for k-CFA and k-obj, which has comparable performance to the state-of-the-art incremental context-insensitive pointer analysis. Our parallelization further improves the performance and enables SHARP to finish within 18 seconds per code commit on average on an eight-core machine.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@article{paperbot1525,
  title = {SHARP: fast incremental context-sensitive pointer analysis for Java},
  author = {Bozhen Liu and Jeff Huang},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {6},
  number = {OOPSLA1},
  year = {2022},
  doi = {10.1145/3527332}
}