paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Synthesizing Invariants for Polynomial Programs by Semidefinite Programming

基于半定规划的多项式程序不变式合成
TOPLAS 47(1)2025匹配度 3/10 · 论文属于程序验证中的多项式程序不变式合成,使用半定规划,与形式化验证方向相邻;但未涉及 LLM/Agent 改进静态分析、浮点程序分析或贝叶斯程序分析,也未聚焦 ML/Agentic 程序的静态分析,因此与当前研究核心交叉点不匹配。引用 5 inbox
Hao Wu, Qiuye Wang, Bai Xue, Naijun Zhan, Lihong Zhi, Zhi-Hong Yang
crossref: 2026-09-10

AI 速览

一句话:用半定规划松弛与鲁棒优化合成多项式程序不变式,分别求解强、弱不变式合成问题并给出理论保证。

基于约束求解的不变式合成把参数化模板的归纳条件编码为约束,其中刻画所有合法参数赋值的问题是强不变式合成,寻找单个可行赋值的问题是弱不变式合成;难点在于约束通常非凸且缺乏高效求解器。本文提出两个基于半定规划(SDP)的算法:Cluster 面向强合成,用鲁棒优化求解一系列 SDP 松弛,得到合法参数集逐步精确的下近似,并证明可靠性、收敛性及特定鲁棒性假设下的弱完备性;Mask 处理该假设不成立时,识别出含参数化多项式等式与已知不等式的掩码模板,通过变量替换将约束化为可用 SDP 松弛求解的等价形式。两者均已实现,实验表明优于现有方法。

问题
如何为多项式程序合成(归纳)不变式:基于约束求解的方法要把参数化模板的归纳条件编码为一般非凸约束,其中强不变式合成需刻画全部合法参数赋值,弱不变式合成需找出一个合法赋值,二者都缺乏高效求解手段。
方法
提出 Cluster 与 Mask 两个基于半定规划(SDP)的算法:前者借助鲁棒优化求解一系列 SDP 松弛,逼近合法参数集合的下近似,从而化简弱合成问题;后者针对鲁棒性假设失效的情形,识别由参数化多项式等式与已知不等式构成的掩码模板,并通过变量替换把约束化为可 SDP 松弛的等价形式。
评估
两个算法均已实现,并在经验评估中与当前最先进方法比较,取得更优性能;作者还给出可靠性、收敛性与特定假设下弱完备性的理论证明。
原文摘要(Abstract)

Constraint-solving-based program invariant synthesis takes a parametric invariant template and encodes the (inductive) invariant conditions into constraints. The problem of characterizing the set of all valid parameter assignments is referred to as the strong invariant synthesis problem , while the problem of finding a concrete valid parameter assignment is called the weak invariant synthesis problem . For both problems, the challenge lies in solving or reducing the encoded constraints, which are generally non-convex and lack efficient solvers. In this article, we propose two novel algorithms for synthesizing invariants of polynomial programs using semidefinite programming (SDP): (1) The Cluster algorithm targets the strong invariant synthesis problem for polynomial invariant templates. Leveraging robust optimization techniques, it solves a series of SDP relaxations and yields a sequence of increasingly precise under-approximations of the set of valid parameter assignments. We prove the algorithm’s soundness, convergence, and weak completeness under a specific robustness assumption on templates. Moreover, the outputs can simplify the weak invariant synthesis problem. (2) The Mask algorithm addresses the weak invariant synthesis problem in scenarios where the aforementioned robustness assumption does not hold, rendering the Cluster algorithm ineffective. It identifies a specific subclass of invariant templates, termed masked templates, involving parameterized polynomial equalities and known inequalities. By applying variable substitution, the algorithm transforms constraints into an equivalent form amenable to SDP relaxations. Both algorithms have been implemented and demonstrated superior performance compared to state-of-the-art methods in our empirical evaluation.

链接与引用

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

BibTeX
@article{WuWXZZY25,
  title = {Synthesizing Invariants for Polynomial Programs by Semidefinite Programming},
  author = {Hao Wu and Qiuye Wang and Bai Xue and Naijun Zhan and Lihong Zhi and Zhi-Hong Yang},
  journal = {ACM Transactions on Programming Languages and Systems},
  volume = {47},
  number = {1},
  year = {2025},
  doi = {10.1145/3708559}
}