paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Using graph neural networks for program termination

使用图神经网络进行程序终止性分析
FSE Proceedings of the 30th ACM Joint European Software Engineering Conference and Symposium on the Foundations of Software Engineering2022匹配度 4/10 · 论文将图神经网络用于程序终止性分析,属于机器学习与程序分析的交叉,但与用户画像的核心方向(LLM/Agent 与静态分析/形式化验证的交叉、浮点程序分析、贝叶斯程序分析、面向 ML/Agentic 程序的静态分析)缺少直接关联。它既未使用 LLM/Agent,也未涉及浮点或贝叶斯程序分析,因此只能算相邻方向的泛读/存档候选。引用 8 inbox
Yoav Alon, Cristina David
crossref: 2026-09-12

AI 速览

一句话:提出用图神经网络估计程序终止行为,并定位可能导致不终止的 AST 节点以辅助调试。

程序终止性分析旨在检测不终止及其引发的挂起、拒绝服务等问题。已有神经网络方法多依赖形式化方法提供可靠性保证,因而受其限制。本文转向随机性机器学习,不追求求解器可解释的严格保证,而是估计程序是否终止以及可能的不终止原因,供程序员调试。作者利用程序的图表示,设计并实现了基于图卷积网络(GCN)和图注意力网络(GAT)的终止性分类器,以及一个语义分割图神经网络,用于定位 AST 中可能导致不终止的节点。文中还展示语义分割信息如何与程序切片结合,进一步辅助调试。

问题
如何在不依赖形式化方法严格保证的前提下,利用机器学习估计程序终止行为,并帮助程序员理解与调试不终止问题。
方法
将程序表示为图,使用基于 GCN 和 GAT 的分类器预测终止性,并设计语义分割 GNN 定位可能致不终止的 AST 节点;同时将注意力与语义分割思想适配到程序,并可与程序切片结合。
评估
作者实现并展示了终止性分类器与语义分割 GNN,说明语义分割信息结合程序切片可辅助调试;摘要未给出具体基准或量化评估结果。
原文摘要(Abstract)

Termination analyses investigate the termination behavior of programs, intending to detect nontermination, which is known to cause a variety of program bugs (e.g. hanging programs, denial-of-service vulnerabilities). Beyond formal approaches, various attempts have been made to estimate the termination behavior of programs using neural networks. However, the majority of these approaches continue to rely on formal methods to provide strong soundness guarantees and consequently suffer from similar limitations. In this paper, we move away from formal methods and embrace the stochastic nature of machine learning models. Instead of aiming for rigorous guarantees that can be interpreted by solvers, our objective is to provide an estimation of a program's termination behavior and of the likely reason for nontermination (when applicable) that a programmer can use for debugging purposes. Compared to previous approaches using neural networks for program termination, we also take advantage of the graph representation of programs by employing Graph Neural Networks. To further assist programmers in understanding and debugging nontermination bugs, we adapt the notions of attention and semantic segmentation, previously used for other application domains, to programs. Overall, we designed and implemented classifiers for program termination based on Graph Convolutional Networks and Graph Attention Networks, as well as a semantic segmentation Graph Neural Network that localizes AST nodes likely to cause nontermination. We also illustrated how the information provided by semantic segmentation can be combined with program slicing to further aid debugging.

链接与引用

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

BibTeX
@inproceedings{paperbot6997,
  title = {Using graph neural networks for program termination},
  author = {Yoav Alon and Cristina David},
  booktitle = {FSE},
  year = {2022},
  doi = {10.1145/3540250.3549095}
}