Program synthesis from denotational semantics

Detalhes bibliográficos
Autor(a) principal: MARANHÃO, Heitor Paceli
Data de Publicação: 2016
Tipo de documento: Dissertação
Idioma: eng
Título da fonte: Repositório Institucional da UFPE
dARK ID: ark:/64986/001300000qd0h
Texto Completo: https://repositorio.ufpe.br/handle/123456789/20828
Resumo: Program synthesis aims to automate the task of programming. Through program synthesis it is possible to let the programmer free to care about the description (specification) of the problem to be solved by the program under development, reducing human interaction with coding tasks. Automating new algorithms creation and transferring responsibility for writing code are some of the benefits propitiated by program synthesis. In this work, program synthesis is presented as an Alloy* specification for an imperative language. We synthesize programs described by pre and post-conditions (contracts) written using a Domain Specific Language proposed in this work. We embed the syntax and the denotational semantics of Winskel’s imperative language in Alloy*. Alloy* has proven to be an easy and productive way of building program synthesizers. Our experiments show that synthesis based on Alloy* is competitive once contracts, scopes and, if needed, sketches, are correctly chosen. As a consequence, our Alloy* program synthesizer can provide, in a single high-level framework, different features in comparison to other synthesizers: (i) synthesis based on scope; (ii) synthesis based on sketches; and (iii) verification. We introduce our Domain Specific Language for contracts and present a detailed description on the synthesis of the swap problem, the product of two numbers, the maximum of 2 and of 3 numbers, and the greatest common divisor. Another contribution of this work is a source code generator, using the programming language C#, of the algorithms created by our synthesizer.
id UFPE_a5a99b8b58f8f91cf568df0f4019558c
oai_identifier_str oai:repositorio.ufpe.br:123456789/20828
network_acronym_str UFPE
network_name_str Repositório Institucional da UFPE
repository_id_str 2221
spelling Program synthesis from denotational semanticsSíntese de programasAlloyLinguagens específicas de domínioProgram synthesis aims to automate the task of programming. Through program synthesis it is possible to let the programmer free to care about the description (specification) of the problem to be solved by the program under development, reducing human interaction with coding tasks. Automating new algorithms creation and transferring responsibility for writing code are some of the benefits propitiated by program synthesis. In this work, program synthesis is presented as an Alloy* specification for an imperative language. We synthesize programs described by pre and post-conditions (contracts) written using a Domain Specific Language proposed in this work. We embed the syntax and the denotational semantics of Winskel’s imperative language in Alloy*. Alloy* has proven to be an easy and productive way of building program synthesizers. Our experiments show that synthesis based on Alloy* is competitive once contracts, scopes and, if needed, sketches, are correctly chosen. As a consequence, our Alloy* program synthesizer can provide, in a single high-level framework, different features in comparison to other synthesizers: (i) synthesis based on scope; (ii) synthesis based on sketches; and (iii) verification. We introduce our Domain Specific Language for contracts and present a detailed description on the synthesis of the swap problem, the product of two numbers, the maximum of 2 and of 3 numbers, and the greatest common divisor. Another contribution of this work is a source code generator, using the programming language C#, of the algorithms created by our synthesizer.Síntese de programas permite automatizar as atividades de programação. Através desta automação é possível deixar o programador livre para criar a descrição (especificação) do problema que o programa a ser desenvolvido busca resolver, reduzindo a interação humana com a etapa de escrita de código. Automatizar criação de novos algoritmos e transferir para máquinas a responsabilidade de escrever o código de programas são alguns dos benefícios que a síntese de programas possibilita. Neste trabalho, síntese de programas é apresentada através de uma especificação em Alloy* usando uma linguagem imperativa. A síntese é realizada a partir de um par de predicados, pré e pós-condição (contrato), escritos usando uma linguagem de domínio específico proposta neste trabalho. A semântica denotacional da linguagem imperativa usada por Winskel foi embutida em Alloy*. O uso de Alloy* se mostrou uma maneira fácil e produtiva de construir sintetizadores de programas. Os experimentos mostram que síntese baseada em Alloy* é competitiva, uma vez que contratos, escopos e, se necessário, esboços, sejam corretamente escolhidos. Como consequência, o sintetizador de programas em Alloy* pode fornecer, em um único framework de alto nível, características diferentes em comparação com outros sintetizadores: (i) síntese baseada em escopo; (ii) síntese baseada em esboços; e (iii) verificação. Para demonstrar a aplicabilidade prática de nosso trabalho, usamos nossa ferramenta na síntese de problemas clássicos da Computação, tais como troca do valor entre duas variáveis, o produto de dois números, o máximo de 2 e 3 números, e o maior divisor comum entre dois números. Outra contribuição deste trabalho consiste em um gerador de código na linguagem de programação C#, dos algoritmos criados pelo nosso sintetizador.Universidade Federal de PernambucoUFPEBrasilPrograma de Pos Graduacao em Ciencia da ComputacaoMOTA, Alexandre CabralIYODA, Juliano Manabuhttp://lattes.cnpq.br/9289621479103917http://lattes.cnpq.br/2794026545404598MARANHÃO, Heitor Paceli2017-08-23T12:57:53Z2017-08-23T12:57:53Z2016-09-13info:eu-repo/semantics/publishedVersioninfo:eu-repo/semantics/masterThesisapplication/pdfhttps://repositorio.ufpe.br/handle/123456789/20828ark:/64986/001300000qd0hengAttribution-NonCommercial-NoDerivs 3.0 Brazilhttp://creativecommons.org/licenses/by-nc-nd/3.0/br/info:eu-repo/semantics/openAccessreponame:Repositório Institucional da UFPEinstname:Universidade Federal de Pernambuco (UFPE)instacron:UFPE2019-10-25T10:45:19Zoai:repositorio.ufpe.br:123456789/20828Repositório InstitucionalPUBhttps://repositorio.ufpe.br/oai/requestattena@ufpe.bropendoar:22212019-10-25T10:45:19Repositório Institucional da UFPE - Universidade Federal de Pernambuco (UFPE)false
dc.title.none.fl_str_mv Program synthesis from denotational semantics
title Program synthesis from denotational semantics
spellingShingle Program synthesis from denotational semantics
MARANHÃO, Heitor Paceli
Síntese de programas
Alloy
Linguagens específicas de domínio
title_short Program synthesis from denotational semantics
title_full Program synthesis from denotational semantics
title_fullStr Program synthesis from denotational semantics
title_full_unstemmed Program synthesis from denotational semantics
title_sort Program synthesis from denotational semantics
author MARANHÃO, Heitor Paceli
author_facet MARANHÃO, Heitor Paceli
author_role author
dc.contributor.none.fl_str_mv MOTA, Alexandre Cabral
IYODA, Juliano Manabu
http://lattes.cnpq.br/9289621479103917
http://lattes.cnpq.br/2794026545404598
dc.contributor.author.fl_str_mv MARANHÃO, Heitor Paceli
dc.subject.por.fl_str_mv Síntese de programas
Alloy
Linguagens específicas de domínio
topic Síntese de programas
Alloy
Linguagens específicas de domínio
description Program synthesis aims to automate the task of programming. Through program synthesis it is possible to let the programmer free to care about the description (specification) of the problem to be solved by the program under development, reducing human interaction with coding tasks. Automating new algorithms creation and transferring responsibility for writing code are some of the benefits propitiated by program synthesis. In this work, program synthesis is presented as an Alloy* specification for an imperative language. We synthesize programs described by pre and post-conditions (contracts) written using a Domain Specific Language proposed in this work. We embed the syntax and the denotational semantics of Winskel’s imperative language in Alloy*. Alloy* has proven to be an easy and productive way of building program synthesizers. Our experiments show that synthesis based on Alloy* is competitive once contracts, scopes and, if needed, sketches, are correctly chosen. As a consequence, our Alloy* program synthesizer can provide, in a single high-level framework, different features in comparison to other synthesizers: (i) synthesis based on scope; (ii) synthesis based on sketches; and (iii) verification. We introduce our Domain Specific Language for contracts and present a detailed description on the synthesis of the swap problem, the product of two numbers, the maximum of 2 and of 3 numbers, and the greatest common divisor. Another contribution of this work is a source code generator, using the programming language C#, of the algorithms created by our synthesizer.
publishDate 2016
dc.date.none.fl_str_mv 2016-09-13
2017-08-23T12:57:53Z
2017-08-23T12:57:53Z
dc.type.status.fl_str_mv info:eu-repo/semantics/publishedVersion
dc.type.driver.fl_str_mv info:eu-repo/semantics/masterThesis
format masterThesis
status_str publishedVersion
dc.identifier.uri.fl_str_mv https://repositorio.ufpe.br/handle/123456789/20828
dc.identifier.dark.fl_str_mv ark:/64986/001300000qd0h
url https://repositorio.ufpe.br/handle/123456789/20828
identifier_str_mv ark:/64986/001300000qd0h
dc.language.iso.fl_str_mv eng
language eng
dc.rights.driver.fl_str_mv Attribution-NonCommercial-NoDerivs 3.0 Brazil
http://creativecommons.org/licenses/by-nc-nd/3.0/br/
info:eu-repo/semantics/openAccess
rights_invalid_str_mv Attribution-NonCommercial-NoDerivs 3.0 Brazil
http://creativecommons.org/licenses/by-nc-nd/3.0/br/
eu_rights_str_mv openAccess
dc.format.none.fl_str_mv application/pdf
dc.publisher.none.fl_str_mv Universidade Federal de Pernambuco
UFPE
Brasil
Programa de Pos Graduacao em Ciencia da Computacao
publisher.none.fl_str_mv Universidade Federal de Pernambuco
UFPE
Brasil
Programa de Pos Graduacao em Ciencia da Computacao
dc.source.none.fl_str_mv reponame:Repositório Institucional da UFPE
instname:Universidade Federal de Pernambuco (UFPE)
instacron:UFPE
instname_str Universidade Federal de Pernambuco (UFPE)
instacron_str UFPE
institution UFPE
reponame_str Repositório Institucional da UFPE
collection Repositório Institucional da UFPE
repository.name.fl_str_mv Repositório Institucional da UFPE - Universidade Federal de Pernambuco (UFPE)
repository.mail.fl_str_mv attena@ufpe.br
_version_ 1846272563660980224