paperbot · PL 论文追踪

全部论文 待读 收藏

P2 CiFi: Versatile Analysis of Class and Field Immutability

CiFi:类与字段不可变性的通用分析
ASE 2021 36th IEEE/ACM International Conference on Automated Software Engineering (ASE)2021匹配度 3/10 · 该论文属于经典静态分析与抽象解释,研究类/字段不可变性,并实现于OPAL框架,与用户关注的“AI与静态分析/Agentic程序”“浮点程序分析”“贝叶斯程序分析”等核心交叉方向无直接关联;仅在静态分析工程实现与benchmark设计上有微弱方法借鉴价值。引用 7 inbox
Tobias Roth, Dominik Helm, Michael Reif, Mira Mezini
crossref: 2026-09-12

AI 速览

一句话:提出统一术语的类与字段不可变性模型,并在 OPAL 上实现模块化协作分析 CiFi,支持惰性初始化与泛型依赖。

不可变性推理对多线程软件等场景的缺陷预防很重要,但已有静态分析多关注单个对象与引用,类与字段层面的不可变性研究较少,术语也不统一。本文提出类与字段不可变性模型,统一既有不可变性分类的术语,并扩展到惰性初始化和依赖泛型类型参数的不可变性。基于 OPAL 静态分析框架,作者实现 CiFi——一组模块化、相互协作的分析,用于推断模型定义的多种不可变性属性。作者还构建代表性测试基准,比较 CiFi 与现有技术的精确率和召回率,并研究真实库中不可变性的普遍性,表明模型具有实用质量与相关性。

问题
如何为类与字段层面的不可变性建立统一模型,并静态推断这些属性,以支持多线程等场景下的推理与缺陷预防。
方法
提出统一术语并覆盖惰性初始化、泛型类型参数依赖的类/字段不可变性模型;基于 OPAL 实现模块化协作分析 CiFi,并设计代表性测试基准。
评估
在自建基准上对比现有技术的精确率与召回率,并分析真实世界库中不可变性的普遍性。
原文摘要(Abstract)

Reasoning about immutability is important for pre-venting bugs, e.g., in multi-threaded software. So far, static analysis to infer immutability properties has mostly focused on individual objects and references. Reasoning about fields and entire classes, while significantly simpler, has gained less attention. Even a consistently used terminology is missing, which makes it difficult to implement analyses that rely on immutability information. We propose a model for class and field immutability that unifies terminology for immutability flavors considered by previous work and covers new levels of immutability to handle lazy initialization and immutability dependent on generic type parameters. Using the OPAL static analysis framework, we implement CiFi, a set of modular, collaborating analyses for different flavors of immutability, inferring the properties defined in our model. Additionally, we propose a benchmark of representative test cases for class and field immutability. We use the benchmark to showcase CiFi’s precision and recall in comparison to state of the art and use CiFi to study the prevalence of immutability in real-world libraries, showcasing the practical quality and relevance of our model.

链接与引用

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

BibTeX
@inproceedings{paperbot6523,
  title = {CiFi: Versatile Analysis of Class and Field Immutability},
  author = {Tobias Roth and Dominik Helm and Michael Reif and Mira Mezini},
  booktitle = {ASE},
  year = {2021},
  doi = {10.1109/ase51524.2021.9678903}
}