This paper is concerned with synthesizing programs based on black-box oracles: we are interested in the case where there exists an executable implementation of a component or library, but its internal structure is unknown. We are provided with just an API or function signature, and aim to synthesize a program with equivalent behavior.
To attack this problem, we detail Presyn: a program synthesizer designed for flexible interoperation with existing programs and compiler toolchains. Presyn uses high-level imperative control-flow structures and a pair of cooperating predictive models to efficiently narrow the space of potential programs. These models can be trained effectively on small corpora of synthesized examples.
We evaluate Presyn against five leading program synthesizers on a collection of 112 synthesis benchmarks collated from previous studies and real-world software libraries. We show that Presyn is able to synthesize a wider range of programs than each of them with less human input. We demonstrate the application of our approach to real-world code and software engineering problems with two case studies: accelerator library porting and detection of duplicated library reimplementations.
Likelihood Hacking in Probabilistic Program Synthesis
University of Oxford, Department of Computer Science(牛津大学计算机科学系);University of Edinburgh, School of Informatics(爱丁堡大学信息学院);CIFAR Fellow, Learning in Machines and Brains(CIFAR Fellow, 机器与大脑学习)
Scaling Neural Program Synthesis with Distribution-based Search
CNRS, LaBRI and Université de Bordeaux(法国国家科学研究中心、波尔多计算机科学实验室与波尔多大学);The Alan Turing Institute of data science(艾伦·图灵数据科学研究所);Cornell University(康奈尔大学);University of Paris(巴黎大学);Indian Institute of Technology Bombay(印度理工学院孟买分校)