A hybrid intermediate language between SSA and CPS

Paulo Torrens, Cristiano Vasconcellos, Ju Gonçalves

Research output: Chapter in Book/Report/Conference proceedingArticle in proceedingsResearchpeer-review

Abstract

Compiler theory is usually studied individually according to the paradigms of the programming language being compiled. As noted by Kelsey, though the static single assignment (SSA) form has been used as intermediate language for imperative language compilers, and some variant of a continuation passing style (CPS) lambda calculus has been used as intermediate language for functional language compilers, they are (almost) equivalent and it is possible to draw syntactic translations between them.

This short paper aims to present an untyped intermediate language which may be interpreted as both SSA and CPS, in order to provide a common language for both imperative and functional compilers, as well to take advantage of optimizations designed for either one of the approaches. Finally, potential variants and research opportunities are discussed.
Compiler theory is usually studied individually according to the paradigms of the programming language being compiled. As noted by Kelsey, though the static single assignment (SSA) form has been used as intermediate language for imperative language compilers, and some variant of a continuation passing style (CPS) lambda calculus has been used as intermediate language for functional language compilers, they are (almost) equivalent and it is possible to draw syntactic translations between them.

This short paper aims to present an untyped intermediate language which may be interpreted as both SSA and CPS, in order to provide a common language for both imperative and functional compilers, as well to take advantage of optimizations designed for either one of the approaches. Finally, potential variants and research opportunities are discussed.
LanguageEnglish
Title of host publicationSBLP 2017 Proceedings of the 21st Brazilian Symposium on Programming Languages
Place of PublicationNew York
PublisherAssociation for Computing Machinery
Date2017
Article number1
ISBN (Print)978-1-4503-5389-2
DOIs
StatePublished - 2017
Event21st Brazilian Symposium on Programming Languages: Part of the 8th Brazilian Conference on Software (CBSoft) - University of Fortaleza, Fortaleza, Brazil
Duration: 21 Sep 201722 Sep 2018
Conference number: 21

Symposium

Symposium21st Brazilian Symposium on Programming Languages
Number21
LocationUniversity of Fortaleza
CountryBrazil
CityFortaleza
Period21/09/201722/09/2018

Cite this

Torrens, P., Vasconcellos, C., & Gonçalves, J. (2017). A hybrid intermediate language between SSA and CPS. In SBLP 2017 Proceedings of the 21st Brazilian Symposium on Programming Languages [1] New York: Association for Computing Machinery. DOI: 10.1145/3125374.3125377
Torrens, Paulo ; Vasconcellos, Cristiano ; Gonçalves, Ju. / A hybrid intermediate language between SSA and CPS. SBLP 2017 Proceedings of the 21st Brazilian Symposium on Programming Languages. New York : Association for Computing Machinery, 2017.
@inproceedings{8bf9a09957564329af4cecc0f7b49d4b,
title = "A hybrid intermediate language between SSA and CPS",
abstract = "Compiler theory is usually studied individually according to the paradigms of the programming language being compiled. As noted by Kelsey, though the static single assignment (SSA) form has been used as intermediate language for imperative language compilers, and some variant of a continuation passing style (CPS) lambda calculus has been used as intermediate language for functional language compilers, they are (almost) equivalent and it is possible to draw syntactic translations between them.This short paper aims to present an untyped intermediate language which may be interpreted as both SSA and CPS, in order to provide a common language for both imperative and functional compilers, as well to take advantage of optimizations designed for either one of the approaches. Finally, potential variants and research opportunities are discussed.",
author = "Paulo Torrens and Cristiano Vasconcellos and Ju Gon{\cc}alves",
year = "2017",
doi = "10.1145/3125374.3125377",
language = "English",
isbn = "978-1-4503-5389-2",
booktitle = "SBLP 2017 Proceedings of the 21st Brazilian Symposium on Programming Languages",
publisher = "Association for Computing Machinery",

}

Torrens, P, Vasconcellos, C & Gonçalves, J 2017, A hybrid intermediate language between SSA and CPS. in SBLP 2017 Proceedings of the 21st Brazilian Symposium on Programming Languages., 1, Association for Computing Machinery, New York, 21st Brazilian Symposium on Programming Languages, Fortaleza, Brazil, 21/09/2017. DOI: 10.1145/3125374.3125377

A hybrid intermediate language between SSA and CPS. / Torrens, Paulo; Vasconcellos, Cristiano; Gonçalves, Ju.

SBLP 2017 Proceedings of the 21st Brazilian Symposium on Programming Languages. New York : Association for Computing Machinery, 2017. 1.

Research output: Chapter in Book/Report/Conference proceedingArticle in proceedingsResearchpeer-review

TY - GEN

T1 - A hybrid intermediate language between SSA and CPS

AU - Torrens,Paulo

AU - Vasconcellos,Cristiano

AU - Gonçalves,Ju

PY - 2017

Y1 - 2017

N2 - Compiler theory is usually studied individually according to the paradigms of the programming language being compiled. As noted by Kelsey, though the static single assignment (SSA) form has been used as intermediate language for imperative language compilers, and some variant of a continuation passing style (CPS) lambda calculus has been used as intermediate language for functional language compilers, they are (almost) equivalent and it is possible to draw syntactic translations between them.This short paper aims to present an untyped intermediate language which may be interpreted as both SSA and CPS, in order to provide a common language for both imperative and functional compilers, as well to take advantage of optimizations designed for either one of the approaches. Finally, potential variants and research opportunities are discussed.

AB - Compiler theory is usually studied individually according to the paradigms of the programming language being compiled. As noted by Kelsey, though the static single assignment (SSA) form has been used as intermediate language for imperative language compilers, and some variant of a continuation passing style (CPS) lambda calculus has been used as intermediate language for functional language compilers, they are (almost) equivalent and it is possible to draw syntactic translations between them.This short paper aims to present an untyped intermediate language which may be interpreted as both SSA and CPS, in order to provide a common language for both imperative and functional compilers, as well to take advantage of optimizations designed for either one of the approaches. Finally, potential variants and research opportunities are discussed.

U2 - 10.1145/3125374.3125377

DO - 10.1145/3125374.3125377

M3 - Article in proceedings

SN - 978-1-4503-5389-2

BT - SBLP 2017 Proceedings of the 21st Brazilian Symposium on Programming Languages

PB - Association for Computing Machinery

CY - New York

ER -

Torrens P, Vasconcellos C, Gonçalves J. A hybrid intermediate language between SSA and CPS. In SBLP 2017 Proceedings of the 21st Brazilian Symposium on Programming Languages. New York: Association for Computing Machinery. 2017. 1. Available from, DOI: 10.1145/3125374.3125377