SYNTHESIS - DREAMS -]PROGRAMS

被引:54
作者
MANNA, Z
WALDINGER, R
机构
[1] Department of Computer Science, Stanford University, Department of Applied Mathematics, Weizmann Institute of Science, Rehovot, Israel
[2] Artificial Intelligence Center, SRI International, Menlo Park
关键词
derivation of programs; Index Terms-Data abstraction; modification of programs; programming methodology; specification of programs; structured programming; synthesis of programs; systematic program development; transformation of programs;
D O I
10.1109/TSE.1979.234198
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Deductive techniques are presented for deriving programs systematically from given specifications. The specifications express the purpose of the desired program without giving any hint of the algorithm to be employed. The basic approach is to transform the specifications repeatedly according to certain rules, until a satisfactory program is produced. The rules are guided by a number of strategic controls. These techniques have been incorporated in a running program-synthesis system, called DEDALUS. Many of the transformation rules represent knowledge about the program's subject domain (e.g., numbers, lists, sets); some represent the meaning of the constructs of the specification language and the target programming language; and a few rules represent basic program. ming principles. Two of these principles, the conditional-formation rule and the recursion-formation rule, account for the introduction of conditional expressions and of recursive calls into the synthesized program. The termination of the program is ensured as new recursive calls are formed. Two extensions of the recursion-formation rule are discussed: A procedure-formationrule, which admits the introduction of auxiliary subroutines in the course of the synthesis process, and a generalization rule, which causes the specifications to be altered to represent a more general problem that is nevertheless easier to solve. Special techniques are introduced for the formation of programs with side effects. The techniques of this paper are illustrated with a sequence of examples of increasing complexity; programs are constructed for list processing, numerical calculation, and array computation. The methods of program synthesis can be applied to various aspects of programming methodology-program transformation, data abstraction, program modification, and structured programming. The DEDALUS system accepts specifications expressed in a high-level language, including set notation, logical quantification, quantification, and a rich vocabulary drawn from a variety of subject domains. The system attempts to transform the specifications into a recursive, Lisp-like target program. Over one hundred rules have been implemented, each expressed as a small program in the QLISP language. Copyright © 1979 by The Institute of Electrical and Electronics Engineers, Inc.
引用
收藏
页码:294 / 328
页数:35
相关论文
共 57 条
[1]  
Aubin R., Some generalization heuristics in proofs by induction, Proc. IRIA Symp. Proving and Improving Programs, pp. 197-208, (1975)
[2]  
Balzer R.M., Automatic programming, (1972)
[3]  
Balzer R.M., Goldman N., Wile D., Informality in program specifications, Proc. 5th Int. Joint Conf. ArtificialIntelligence, pp. 389-397, (1977)
[4]  
Barstow D., A knowledge-based system for automatic program construction, Proc. 5th Int. Joint Conf. Artificial Intelligence, pp. 382-388, (1977)
[5]  
Biermann A.W., Approaches to automatic programming, Advances in Computers, 15, pp. 1-63, (1976)
[6]  
Biermann A.W., Krishnaswamy R., Constructing programs from example computations, IEEE Trans. Software Eng., SE-2, pp. 141-153, (1976)
[7]  
Bledsoe W.W., Tyson M., Typing and proof by cases inprogram verification, Machine Intelligence 8: Machine Representations of Knowledge, pp. 30-51, (1977)
[8]  
Boyer R.S., Moore J.S., Proving theorems about LISP functions, J. Ass. Comput. Mach., 22, pp. 129-144, (1975)
[9]  
A lemma driven automatic theorem prover for recursive function theory, Proc. 5th Int. Joint Conf. Artificial Intelligence, pp. 511-519, (1977)
[10]  
Brotz D., Proving theorems by mathematical induction, Ph.D. dissertation, Comput. Sci. Dep., Stanford Univ., Stanford, CA, (1973)