非线性实数算术的程序合成:超越可实现性
Program Synthesis for Non-Linear Real Arithmetic: Going Beyond Realizability
AI总结:
研究从任意非线性实数算术规范中合成程序的问题,提出在规范不可实现时仍能输出满足规范或报告无解的程序,并给出单输出变量的完备算法和一般情况下的不完备算法。
摘要:
我们研究从非线性实数算术(NRA)规范合成程序的问题。现有技术(如语法引导合成SyGuS)在规范不可实现时无法合成程序。我们认为这在许多情况下是不令人满意的,并旨在从任意NRA规范合成程序,使得对于任何输入,合成的程序要么产生满足规范的输出,要么报告不存在任何这样的输出。为避免浮点算术固有的舍入误差,我们将程序限制为在有理数输入和输出上工作。我们首先证明我们的合成问题变体与数论中一个长期未决的开放问题一样困难,并且从任意具有有理数输入和输出的NRA规范合成无环程序在一般情况下是不可能的。其次,我们针对规范涉及单个输出变量的情况,提出一个完备的合成算法。我们还表明,对于可实现规范,SyGuS为NRA(实数输入和输出)生成的程序可作为我们问题的一个解,其中输入和输出为有理数。第三,我们为一般情况下的规范提供一个完备(但必然不完备)的合成算法。我们已在名为NQSynth的原型工具中实现了我们的方法,该工具解决了许多超出最先进SyGuS工具能力的基准测试,即使我们使规范可实现也是如此。
英文摘要:
We study the problem of synthesizing programs from nonlinear real arithmetic (NRA) specifications. Existing techniques, such as syntax-guided synthesis (SyGuS), fail to synthesize programs when the specification is unrealizable. We argue this is unsatisfactory in many situations, and aim to synthesize programs from arbitrary NRA specifications, such that for any input, the synthesized program either produces outputs satisfying the specification or reports non-existence of any such output. To avoid rounding errors inherent in floating-point arithmetic, we restrict our programs to work on rational inputs and outputs. We first show that our variant of the synthesis problem is as hard as a long-standing open problem in number theory, and that synthesizing loop-free programs from arbitrary NRA specifications with rational inputs and outputs is impossible in general. Second, we present a sound and complete synthesis algorithm for the case where the specification involves a single output variable. We also show that for realizable specifications, a program generated by SyGuS for NRA (real inputs and outputs) serves as a solution to our problem, where inputs and outputs are rationals. Third, we provide a sound (but necessarily incomplete) synthesis algorithm for the general case of specifications. We have implemented our approach in a prototype tool called NQSynth that solves many benchmarks beyond the reach of state-of-the-art SyGuS tools, even when we render the specifications realizable.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。