Tail Call Elimination and Data Representation for Functional Languages on the Java Virtual Machine

Research output: Contribution to book/anthology/report/proceedingArticle in proceedingsResearchpeer-review

Standard

Tail Call Elimination and Data Representation for Functional Languages on the Java Virtual Machine. / Madsen, Magnus; Zarifi, Ramin; Lhoták, Ondrej.

CC 2018 - Proceedings of the 27th International Conference on Compiler Construction, Co-located with CGO 2018. ed. / Jingling Xue; Christophe Dubach. New York, NY, USA : Association for Computing Machinery, 2018. p. 139-150 (CC 2018).

Research output: Contribution to book/anthology/report/proceedingArticle in proceedingsResearchpeer-review

Harvard

Madsen, M, Zarifi, R & Lhoták, O 2018, Tail Call Elimination and Data Representation for Functional Languages on the Java Virtual Machine. in J Xue & C Dubach (eds), CC 2018 - Proceedings of the 27th International Conference on Compiler Construction, Co-located with CGO 2018. Association for Computing Machinery, New York, NY, USA, CC 2018, pp. 139-150, International Conference on Compiler Construction , Vienna, Austria, 24/02/2018. https://doi.org/10.1145/3178372.3179499

APA

Madsen, M., Zarifi, R., & Lhoták, O. (2018). Tail Call Elimination and Data Representation for Functional Languages on the Java Virtual Machine. In J. Xue, & C. Dubach (Eds.), CC 2018 - Proceedings of the 27th International Conference on Compiler Construction, Co-located with CGO 2018 (pp. 139-150). Association for Computing Machinery. CC 2018 https://doi.org/10.1145/3178372.3179499

CBE

Madsen M, Zarifi R, Lhoták O. 2018. Tail Call Elimination and Data Representation for Functional Languages on the Java Virtual Machine. Xue J, Dubach C, editors. In CC 2018 - Proceedings of the 27th International Conference on Compiler Construction, Co-located with CGO 2018. New York, NY, USA: Association for Computing Machinery. pp. 139-150. (CC 2018). https://doi.org/10.1145/3178372.3179499

MLA

Madsen, Magnus, Ramin Zarifi and Ondrej Lhoták "Tail Call Elimination and Data Representation for Functional Languages on the Java Virtual Machine". and Xue, Jingling Dubach, Christophe (editors). CC 2018 - Proceedings of the 27th International Conference on Compiler Construction, Co-located with CGO 2018. New York, NY, USA: Association for Computing Machinery. (CC 2018). 2018, 139-150. https://doi.org/10.1145/3178372.3179499

Vancouver

Madsen M, Zarifi R, Lhoták O. Tail Call Elimination and Data Representation for Functional Languages on the Java Virtual Machine. In Xue J, Dubach C, editors, CC 2018 - Proceedings of the 27th International Conference on Compiler Construction, Co-located with CGO 2018. New York, NY, USA: Association for Computing Machinery. 2018. p. 139-150. (CC 2018). https://doi.org/10.1145/3178372.3179499

Author

Madsen, Magnus ; Zarifi, Ramin ; Lhoták, Ondrej. / Tail Call Elimination and Data Representation for Functional Languages on the Java Virtual Machine. CC 2018 - Proceedings of the 27th International Conference on Compiler Construction, Co-located with CGO 2018. editor / Jingling Xue ; Christophe Dubach. New York, NY, USA : Association for Computing Machinery, 2018. pp. 139-150 (CC 2018).

Bibtex

@inproceedings{fa9d9afd8d8548dc9cc2e922cbeabbda,
title = "Tail Call Elimination and Data Representation for Functional Languages on the Java Virtual Machine",
abstract = "The Java Virtual Machine (JVM) offers an attractive runtime environment for programming language implementors. The JVM has a simple bytecode format, excellent performance, multiple state-of-the art garbage collectors, robust backwards compatibility, and it runs on almost all platforms. Further, the Java ecosystem grants access to a plethora of libraries and tooling, including debuggers and profilers. Yet, the JVM was originally designed for Java, and its representation of code and data may cause difficulties for other languages. In this paper, we discuss how to efficiently implement functional languages on the JVM. We focus on two overall challenges: (a) how to efficiently represent algebraic data types in the presence of tags and tuples, option types, newtypes, and parametric polymorphism, and (b) how to support full tail call elimination on the JVM. We present two technical contributions: A fused representation of tags and tuples and a full tail call elimination strategy that is thread-safe. We implement these techniques in the Flix language and evaluate their performance.",
keywords = "java, jvm, tag tuple fusion, tail call elimination, Java, Jvm, Tag tuple fusion, Tail call elimination",
author = "Magnus Madsen and Ramin Zarifi and Ondrej Lhot{\'a}k",
year = "2018",
month = feb,
day = "24",
doi = "10.1145/3178372.3179499",
language = "English",
isbn = "978-1-4503-5644-2",
series = "CC 2018",
pages = "139--150",
editor = "Jingling Xue and Christophe Dubach",
booktitle = "CC 2018 - Proceedings of the 27th International Conference on Compiler Construction, Co-located with CGO 2018",
publisher = "Association for Computing Machinery",
note = "null ; Conference date: 24-02-2018 Through 25-02-2018",
url = "https://cc-conference.github.io/18/",

}

RIS

TY - GEN

T1 - Tail Call Elimination and Data Representation for Functional Languages on the Java Virtual Machine

AU - Madsen, Magnus

AU - Zarifi, Ramin

AU - Lhoták, Ondrej

N1 - Conference code: 27

PY - 2018/2/24

Y1 - 2018/2/24

N2 - The Java Virtual Machine (JVM) offers an attractive runtime environment for programming language implementors. The JVM has a simple bytecode format, excellent performance, multiple state-of-the art garbage collectors, robust backwards compatibility, and it runs on almost all platforms. Further, the Java ecosystem grants access to a plethora of libraries and tooling, including debuggers and profilers. Yet, the JVM was originally designed for Java, and its representation of code and data may cause difficulties for other languages. In this paper, we discuss how to efficiently implement functional languages on the JVM. We focus on two overall challenges: (a) how to efficiently represent algebraic data types in the presence of tags and tuples, option types, newtypes, and parametric polymorphism, and (b) how to support full tail call elimination on the JVM. We present two technical contributions: A fused representation of tags and tuples and a full tail call elimination strategy that is thread-safe. We implement these techniques in the Flix language and evaluate their performance.

AB - The Java Virtual Machine (JVM) offers an attractive runtime environment for programming language implementors. The JVM has a simple bytecode format, excellent performance, multiple state-of-the art garbage collectors, robust backwards compatibility, and it runs on almost all platforms. Further, the Java ecosystem grants access to a plethora of libraries and tooling, including debuggers and profilers. Yet, the JVM was originally designed for Java, and its representation of code and data may cause difficulties for other languages. In this paper, we discuss how to efficiently implement functional languages on the JVM. We focus on two overall challenges: (a) how to efficiently represent algebraic data types in the presence of tags and tuples, option types, newtypes, and parametric polymorphism, and (b) how to support full tail call elimination on the JVM. We present two technical contributions: A fused representation of tags and tuples and a full tail call elimination strategy that is thread-safe. We implement these techniques in the Flix language and evaluate their performance.

KW - java, jvm, tag tuple fusion, tail call elimination

KW - Java

KW - Jvm

KW - Tag tuple fusion

KW - Tail call elimination

U2 - 10.1145/3178372.3179499

DO - 10.1145/3178372.3179499

M3 - Article in proceedings

SN - 978-1-4503-5644-2

T3 - CC 2018

SP - 139

EP - 150

BT - CC 2018 - Proceedings of the 27th International Conference on Compiler Construction, Co-located with CGO 2018

A2 - Xue, Jingling

A2 - Dubach, Christophe

PB - Association for Computing Machinery

CY - New York, NY, USA

Y2 - 24 February 2018 through 25 February 2018

ER -